File Element (Upgrade)
Applies to: SharePoint Foundation 2010
Describes the relationship between an existing provisioned file to its equivalent file for upgrading to Microsoft SharePoint Foundation 2010, specifying how setup paths of files in the previous version map (relate) to setup paths in the new version relative to their %ProgramFiles%\Common Files\Microsoft Shared\web server extensions\14\TEMPLATE directories.
<File
FromPath = "String"
ToPath = "String">
</File>
Attributes
Attribute |
Description |
---|---|
FromPath |
Required String. Specifies the setup path of the file to be upgraded relative to the %ProgramFiles%\Common Files\Microsoft Shared\web server extensions\14\TEMPLATE directory. Use the token {LocaleId} to specify a locale identifier as part of the path. Example: FromPath="{LocaleId}\STS\Lists\announce\EditForm.aspx" |
ToPath |
Required String. Specifies the location in the setup directory of the file to which the file of the old version is mapped relative to the %ProgramFiles%\Common Files\Microsoft Shared\web server extensions\14\TEMPLATE directory. Example: ToPath= "Features\AnnouncementsList\announce\EditForm.aspx" |
Child Elements
None |
Parent Elements
Occurrences
Minimum: 0 Maximum: Unbounded |
Remarks
File upgrades can be applied to any sort of uncustomized file, usually .aspx pages, but also to entities such as document templates. In the upgrade definition it is best to list all previously installed uncustomized (also known as "ghosted") files, including ones that were provisioned as part of a list, or files located only in the top-level Web site, such as .dwp files for Web Parts.
SharePoint Foundation supports a {LocaleId} token, which specifies the locale identifier to be included as part of the path. This makes it possible to map locale-specific files.
For an example of how this element is used, see Upgrade Definition Schema.