mirror of
https://github.com/MicrosoftDocs/windows-itpro-docs.git
synced 2025-06-16 02:43:43 +00:00
Updated-5548201
Converted HTML tables to Markdown tables in the following topics Offline Migration Reference Understanding Migration XML Files Choose a Migration Store Type User State Migration Tool (USMT) Command-line Syntax Config.xml File Conflicts and Precedence Custom XML Examples Determine What to Migrate Hard-Link Migration Store LoadState Syntax Log Files Migration Store Encryption Plan Your Migration Recognized Environment Variables User State Migration Toolkit (USMT) Reference
This commit is contained in:
@ -15,15 +15,11 @@ ms.topic: article
|
||||
|
||||
# Custom XML Examples
|
||||
|
||||
|
||||
**Note**
|
||||
Because the tables in this topic are wide, you may need to adjust the width of its window.
|
||||
|
||||
|
||||
|
||||
## In This Topic:
|
||||
|
||||
|
||||
- [Example 1: Migrating an Unsupported Application](#example)
|
||||
|
||||
- [Example 2: Migrating the My Videos Folder](#example2)
|
||||
@ -34,7 +30,6 @@ Because the tables in this topic are wide, you may need to adjust the width of i
|
||||
|
||||
## <a href="" id="example"></a>Example 1: Migrating an Unsupported Application
|
||||
|
||||
|
||||
The following is a template for the sections that you need to migrate your application. The template is not functional on its own, but you can use it to write your own .xml file.
|
||||
|
||||
``` xml
|
||||
@ -103,37 +98,13 @@ The following is a template for the sections that you need to migrate your appli
|
||||
|
||||
## <a href="" id="example2"></a>Example 2: Migrating the My Videos Folder
|
||||
|
||||
|
||||
The following is a custom .xml file named CustomFile.xml that migrates My Videos for all users, if the folder exists on the source computer.
|
||||
|
||||
<table>
|
||||
<colgroup>
|
||||
<col width="50%" />
|
||||
<col width="50%" />
|
||||
</colgroup>
|
||||
<thead>
|
||||
<tr class="header">
|
||||
<th align="left">Code</th>
|
||||
<th align="left">Behavior</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
<tr class="odd">
|
||||
<td align="left"><pre class="syntax"><code><condition>MigXmlHelper.DoesObjectExist("File","%CSIDL_MYVIDEO%")</condition></code></pre></td>
|
||||
<td align="left"><p>Verifies that My Videos exists on the source computer.</p></td>
|
||||
</tr>
|
||||
<tr class="even">
|
||||
<td align="left"><pre class="syntax"><code><include filter='MigXmlHelper.IgnoreIrrelevantLinks()'></code></pre></td>
|
||||
<td align="left"><p>Filters out the shortcuts in My Videos that do not resolve on the destination computer. This has no effect on files that are not shortcuts. For example, if there is a shortcut in My Videos on the source computer that points to C:\Folder1, that shortcut will be migrated only if C:\Folder1 exists on the destination computer. However, all other files, such as .mp3 files, migrate without any filtering.</p></td>
|
||||
</tr>
|
||||
<tr class="odd">
|
||||
<td align="left"><pre class="syntax"><code><pattern type="File">%CSIDL_MYVIDEO%* [*]</pattern></code></pre></td>
|
||||
<td align="left"><p>Migrates My Videos for all users.</p></td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
|
||||
|
||||
| Code | Behavior |
|
||||
|------|----------|
|
||||
| <pre class="syntax"><code><condition>MigXmlHelper.DoesObjectExist("File","%CSIDL_MYVIDEO%")</condition></code></pre> | Verifies that My Videos exists on the source computer. |
|
||||
| <pre class="syntax"><code><include filter='MigXmlHelper.IgnoreIrrelevantLinks()'></code></pre> | Filters out the shortcuts in My Videos that do not resolve on the destination computer. This has no effect on files that are not shortcuts. For example, if there is a shortcut in My Videos on the source computer that points to C:\Folder1, that shortcut will be migrated only if C:\Folder1 exists on the destination computer. However, all other files, such as .mp3 files, migrate without any filtering. |
|
||||
| <pre class="syntax"><code><pattern type="File">%CSIDL_MYVIDEO%* [*]</pattern></code></pre> | Migrates My Videos for all users. |
|
||||
|
||||
```xml
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
@ -160,41 +131,14 @@ The following is a custom .xml file named CustomFile.xml that migrates My Videos
|
||||
|
||||
## <a href="" id="example3"></a>Example 3: Migrating Files and Registry Keys
|
||||
|
||||
|
||||
This table describes the behavior in the following example .xml file.
|
||||
|
||||
<table>
|
||||
<colgroup>
|
||||
<col width="50%" />
|
||||
<col width="50%" />
|
||||
</colgroup>
|
||||
<thead>
|
||||
<tr class="header">
|
||||
<th align="left">Code</th>
|
||||
<th align="left">Behavior</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
<tr class="odd">
|
||||
<td align="left"><pre class="syntax"><code><pattern type="File">%ProgramFiles%\USMTTestFolder* [USMTTestFile.txt]</pattern></code></pre></td>
|
||||
<td align="left"><p>Migrates all instances of the file Usmttestfile.txt from all sub-directories under %ProgramFiles%\USMTTestFolder.</p></td>
|
||||
</tr>
|
||||
<tr class="even">
|
||||
<td align="left"><pre class="syntax"><code><pattern type="File">%ProgramFiles%\USMTDIRTestFolder* [<em>]</pattern></code></pre></td>
|
||||
<td align="left"><p>Migrates the whole directory under %ProgramFiles%\USMTDIRTestFolder.</p></td>
|
||||
</tr>
|
||||
<tr class="odd">
|
||||
<td align="left"><pre class="syntax"><code><pattern type="Registry">HKCU\Software\USMTTESTKEY* [MyKey]</pattern></code></pre></td>
|
||||
<td align="left"><p>Migrates all instances of MyKey under HKCU\Software\USMTTESTKEY.</p></td>
|
||||
</tr>
|
||||
<tr class="even">
|
||||
<td align="left"><pre class="syntax"><code><pattern type="Registry">HKLM\Software\USMTTESTKEY* [</em>]</pattern></code></pre></td>
|
||||
<td align="left"><p>Migrates the entire registry hive under HKLM\Software\USMTTESTKEY.</p></td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
|
||||
|
||||
| Code | Behavior |
|
||||
|------|----------|
|
||||
| <pre class="syntax"><code><pattern type="File">%ProgramFiles%\USMTTestFolder* [USMTTestFile.txt]</pattern></code></pre> | Migrates all instances of the file Usmttestfile.txt from all sub-directories under %ProgramFiles%\USMTTestFolder. |
|
||||
| <pre class="syntax"><code><pattern type="File">%ProgramFiles%\USMTDIRTestFolder* []</pattern></code></pre> | Migrates the whole directory under %ProgramFiles%\USMTDIRTestFolder. |
|
||||
| <pre class="syntax"><code><pattern type="Registry">HKCU\Software\USMTTESTKEY* [MyKey]</pattern></code></pre> | Migrates all instances of MyKey under HKCU\Software\USMTTESTKEY. |
|
||||
| <pre class="syntax"><code><pattern type="Registry">HKLM\Software\USMTTESTKEY* []</pattern></code></pre> | Migrates the entire registry hive under HKLM\Software\USMTTESTKEY. |
|
||||
|
||||
``` xml
|
||||
<migration urlid="http://www.microsoft.com/migration/1.0/migxmlext/testfilemig">
|
||||
@ -303,16 +247,6 @@ The behavior for this custom .xml file is described within the <`displayName`
|
||||
|
||||
## Related topics
|
||||
|
||||
|
||||
[USMT XML Reference](usmt-xml-reference.md)
|
||||
|
||||
[Customize USMT XML Files](usmt-customize-xml-files.md)
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
Reference in New Issue
Block a user