Media Table

[This is preliminary documentation and subject to change.]

The Media table describes the set of disks that make up the source media for the installation.

The Media table has the following columns.

Column Type Key Nullable
DiskId Integer Y N
LastSequence Integer N
DiskPrompt Text Y
Cabinet Cabinet Y
VolumeLabel Text Y
Source Property Y

Columns

DiskId
Determines the sort order for the table.

Non-negative numbers only. Minimum value is 1.

LastSequence
File sequence number for the last file for this media.

Non-negative numbers only.

DiskPrompt
Disk name, the visible text printed on the disk. This is used to prompt the user when this disk needs to be inserted.
Cabinet
The name of the cabinet if some or all of the files stored on the media are compressed in a cabinet. If cabinets are not being used, this column must be blank (or the entire column can be omitted).
VolumeLabel
The label attributed to the volume. This is the volume label returned by the GetVolumeInformation system API. If the SOURCEDIR property refers to a removable (floppy or CD-ROM) volume, this volume label is used to verify that the proper disk is in the drive before attempting to install files.
Source
The property defining the location of this cabinet file. If the Cabinet field is empty, this value is ignored. If this field is empty, the SOURCEDIR property is used.

Remarks

Sequence Numbers

The numbers in the LastSequence column specify which of the files in the File table are found on a particular source disk. Each source disk contains all the files whose sequence numbers (as shown in the Sequence column of the File table) are less than or equal to the value in the LastSequence column, and greater than the LastSequence value of the previous disk (or greater than 0, for the first entry in the Media table).

Cabinet Files

If the Cabinet name is preceded by an at symbol (@), the files referencing this Media table record are packed in a cabinet that is stored within a resource of the launching executable file.

Determining the SourceMode

The MSI Source Type Summary property determines the source mode for the current install. If this property is set to 2 or 3, a cabinet install is assumed. In this mode, the cabinet files are assumed to exist in the directory indicated by the SOURCEDIR property. If the Source Type value is 0 or 1, all source files are assumed to exist in the tree whose root is indicated by the SOURCEDIR property.

Note that this only applies to files in the File table that do not have either the Compressed or Uncompressed bits set in the attributes column. These bits override the value of the MSI Source Type Summary property when determining if a particular file is compressed or uncompressed.