Description
Environment variables added or removed for the parent component.
Derived By
Restricting anyType
Attributes
| Name |
Type |
Required? |
Default |
Description |
| Id |
string |
Yes |
|
Unique identifier for environment entry.
|
| Name |
string |
Yes |
|
Name of the environment variable.
|
| Value |
string |
No |
|
The value to set into the environment variable.
|
| Separator |
string |
No |
|
Optional attribute to change the separator used between values.
|
| Action |
NMTOKEN (restriction) |
No |
|
Specfies whether the environmental variable should be created, set or removed when the parent component is installed.
|
| Part |
NMTOKEN (restriction) |
No |
|
|
| Permanent |
YesNoType |
No |
|
Specifies that the environment variable should not be removed on uninstall.
|
| System |
YesNoType |
No |
|
Specifies that the environment variable should be added to the system environment space.
|
Content Model
Always empty.
Referenced By
Definition
<xs:element name="Environment">
<xs:annotation>
<xs:documentation>
Environment variables added or removed for the parent component.
</xs:documentation>
<xs:appinfo>
<xse:msiRef table="Environment" href="http://msdn.microsoft.com/library/aa368369.aspx" xmlns:xse="http://schemas.microsoft.com/wix/2005/XmlSchemaExtension" />
</xs:appinfo>
</xs:annotation>
<xs:complexType>
<xs:attribute name="Id" type="xs:string" use="required">
<xs:annotation>
<xs:documentation>Unique identifier for environment entry.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="Name" type="xs:string" use="required">
<xs:annotation>
<xs:documentation>Name of the environment variable.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="Value" type="xs:string">
<xs:annotation>
<xs:documentation>
The value to set into the environment variable.
If this attribute is not set, the environment variable is removed during installation if it exists on the machine.
</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="Separator" type="xs:string">
<xs:annotation>
<xs:documentation>Optional attribute to change the separator used between values. By default a semicolon is used.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="Action">
<xs:annotation>
<xs:documentation>Specfies whether the environmental variable should be created, set or removed when the parent component is installed.</xs:documentation>
</xs:annotation>
<xs:simpleType>
<xs:restriction base="xs:NMTOKEN">
<xs:enumeration value="create">
<xs:annotation>
<xs:documentation>Creates the environment variable if it does not exist, then set it during installation. This has no effect on the value of the environment variable if it already exists.</xs:documentation>
</xs:annotation>
</xs:enumeration>
<xs:enumeration value="set">
<xs:annotation>
<xs:documentation>Creates the environment variable if it does not exist, and then set it during installation. If the environment variable exists, set it during the installation.</xs:documentation>
</xs:annotation>
</xs:enumeration>
<xs:enumeration value="remove">
<xs:annotation>
<xs:documentation>
Removes the environment variable during an installation.
The installer only removes an environment variable during an installation if the name and value
of the variable match the entries in the Name and Value attributes.
If you want to remove an environment variable, regardless of its value, do not set the Value attribute.
</xs:documentation>
</xs:annotation>
</xs:enumeration>
</xs:restriction>
</xs:simpleType>
</xs:attribute>
<xs:attribute name="Part">
<xs:simpleType>
<xs:restriction base="xs:NMTOKEN">
<xs:enumeration value="all">
<xs:annotation>
<xs:documentation>
This value is the entire environmental variable. This is the default.
</xs:documentation>
</xs:annotation>
</xs:enumeration>
<xs:enumeration value="first">
<xs:annotation>
<xs:documentation>
This value is prefixed.
</xs:documentation>
</xs:annotation>
</xs:enumeration>
<xs:enumeration value="last">
<xs:annotation>
<xs:documentation>
This value is appended.
</xs:documentation>
</xs:annotation>
</xs:enumeration>
</xs:restriction>
</xs:simpleType>
</xs:attribute>
<xs:attribute name="Permanent" type="YesNoType">
<xs:annotation>
<xs:documentation>Specifies that the environment variable should not be removed on uninstall.</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="System" type="YesNoType">
<xs:annotation>
<xs:documentation>
Specifies that the environment variable should be added to the system environment space. The default
is 'no' which indicates the environment variable is added to the user environment space.
</xs:documentation>
</xs:annotation>
</xs:attribute>
</xs:complexType>
</xs:element>