You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The Package element is the top-level XML element inside of a package file. The Package element is required.
ms.date
11/04/2016
ms.topic
reference
dev_langs
FSharp
VB
CSharp
C++
helpviewer_keywords
<package> element [bootstrapper]
author
mikejo5000
ms.author
mikejo
ms.subservice
deployment
<Package> element (bootstrapper)
The Package element is the top-level XML element inside of a package file.
Syntax
<Package
Culture
Name
LicenseAgreement
>
<InstallChecks>
<AssemblyCheck
Property
Name
PublicKeyToken
Version
Language
ProcessorArchitecture
/>
<RegistryCheck
Property
Key
Value
/>
<ExternalCheck
PackageFile
Property
Arguments
Log
/>
<FileCheck
Property
FileName
SearchPath
SpecialFolder
SearchDepth
/>
<MsiProductCheck
Property
Product
Feature
/>
<RegistryFileCheck
Property
Key
Value
File
SearchDepth
/>
</InstallChecks>
<Commands
Reboot
>
<Command
PackageFile
Arguments
EstimatedInstallSeconds
EstimatedDiskBytes
EstimatedTempBytes
Log
>
<InstallConditions>
<BypassIf
Property
Compare
Value
Schedule
/>
<FailIf
Property
Compare
Value
String
Schedule
/>
</InstallConditions>
<ExitCodes>
<ExitCode
Value
Result
String
/>
</ExitCodes>
</Command>
</Commands>
<PackageFiles
CopyAllComponents
>
<PackageFile
Name
Path
HomeSite
PublicKey
/>
</PackageFiles>
<Strings>
<String
Name
>
</String>
</Strings>
<Schedules>
<Schedule
Name
>
<BuildList />
<BeforePackage />
<AfterPackage />
</Schedule>
</Schedules>
</Package>
Elements and attributes
The Package element is required. It has the following attributes.
Attribute
Description
Culture
Required. Defines the culture for this package, which determines the language to be used. This attribute is a key into the Strings element, which lists culture-specific strings for product names and error messages during the installation.
Name
Required. The name of the package displayed to the developer within a tool such as Visual Studio. This attribute is a key into the Strings element, which should contain a String element with the Name and Culture properties set to match the Name and Culture properties of Package.
LicenseAgreement
Optional. Specifies the name of the file in the distribution package which contains the End-User License Agreement (EULA). This file can be either plain text (.txt) or Rich Text Format. (.rtf)
Example
The following code example shows a complete package file for redistributing the .NET Framework 2.0.
<?xml version="1.0" encoding="utf-8" ?>
<Packagexmlns="http://schemas.microsoft.com/developer/2004/01/bootstrapper"Name="DisplayName"Culture="Culture"LicenseAgreement="eula.rtf"
>
<PackageFiles>
<PackageFileName="eula.rtf"/>
</PackageFiles>
<!-- Defines a localizable string table for error messages-->
<Strings>
<StringName="DisplayName">.NET Framework 2.0</String>
<StringName="Culture">en</String>
<StringName="AdminRequired">Administrator permissions are required to install the .NET Framework 2.0. Contact your administrator.</String>
<StringName="InvalidPlatformWin9x">Installation of the .NET Framework 2.0 is not supported on Windows 95. Contact your application vendor.</String>
<StringName="InvalidPlatformWinNT">Installation of the .NET Framework 2.0 is not supported on Windows NT 4.0. Contact your application vendor.</String>
<StringName="InvalidPlatformIE">Installation of the .NET Framework 2.0 requires Internet Explorer 5.01 or greater. Contact your application vendor.</String>
<StringName="InvalidPlatformArchitecture">This version of the .NET Framework 2.0 is not supported on a 64-bit operating system. Contact your application vendor.</String>
<StringName="WindowsInstallerImproperInstall">Due to an error with Windows Installer, the installation of the .NET Framework 2.0 cannot proceed.</String>
<StringName="AnotherInstanceRunning">Another instance of setup is already running. The running instance must complete before this setup can proceed.</String>
<StringName="BetaNDPFailure">A beta version of the .NET Framework was detected on the computer. Uninstall any previous beta versions of .NET Framework before continuing.</String>
<StringName="GeneralFailure">A failure occurred attempting to install the .NET Framework 2.0.</String>
<StringName="DotNetFXExe">http://go.microsoft.com/fwlink/?LinkId=37283</String>
<StringName="InstMsiAExe">http://go.microsoft.com/fwlink/?LinkId=37285</String>
<StringName="Msi30Exe">http://go.microsoft.com/fwlink/?LinkId=37287</String>
</Strings>
</Package>