Package element
The Package element is analogous to the main function in a C program. When linking, only one Package section can be given to the build to produce a successful result. Using this element creates an MSI file which often referred to as a Product.
Attributes
Codepage
stringThe code page integer value or web name for the resulting MSI. See remarks for more information. The default codepage is 65001 (UTF-8).
Compressed
yesnoIndicates whether the package files are compressed. Default is compressed packages.
Id
stringNew in WiX v6: WiX v6 adds this attribute to the Package
element.
A globally unique identiifer for the package in the world. It is recommended to use a prefix such as “CompanyName.” to
create a namespace of sorts. By default, higher versioned upgrade lower versioned packages with the same Id. Use this
attibute instead of the UpgradeCode attribute in new development.
InstallerVersion
IntegerThe minimum version of the Windows Installer required to install this package. Take the major version of the required Windows Installer and multiply by a 100 then add the minor version of the Windows Installer. For example, “200” would represent Windows Installer 2.0 and “405” would represent Windows Installer 4.5. This value is defaulted to “500” which is the latest version of the Windows Installer and present in Windows 7 and later.
Language
LocalizableIntegerThe decimal language ID (LCID) for the product. Sets the ProductLanguage property.
Manufacturer
string requiredThe manufacturer of the package. Sets the Manufacturer property.
Name
string requiredThe descriptive name of the product. Sets the ProductName property.
ProductCode
AutogenGuidOptional ProductCode GUID for the package. By default, a new ProductCode property will be generated with every build enabling major upgrades.
Scope
PackageScopeTypeUnionUse this attribute to specify the installation scope of this package: per-machine, per-user, or a choice of either. The default is per-machine.
ShortNames
yesnoIndicates whether the package files are installed using 8.3 filenames. The default is no.
UpgradeCode
GuidFor new packages, it is recommended to use the Id attribute instead. This attribute exists for backwards compatibility scenarios. Use this attribute to provide a specific upgrade code GUID for a MSI package. See UpgradeCode for more information.
UpgradeStrategy
UpgradeStrategyTypeUnionNew in WiX v5: WiX v5 adds this attribute to the Package
element.
The upgrade strategy for the package. If “none,” no major upgrade is expected.
If “majorUpgrade,” the UpgradeCode attribute is required and a major upgrade is expected.
The default is “majorUpgrade.”
A default major upgrade is automatically provided if none is authored.
Version
string requiredThe product’s version string. Sets the ProductVersion property.
Children
Parents
Remarks
You can specify any valid Windows code page by integer like 1252, or by web name like Windows-1252. See Code pages for more information.