Previous Next

INF ControlFlags Section

[ControlFlags]
 

ExcludeFromSelect=* |
ExcludeFromSelect=device-identification-string[,device-identification-string] ...
[ExcludeFromSelect.nt=device-identification-string[,device-identification-string] ...]
[ExcludeFromSelect.ntx86=device-identification-string[,device-identification-string] ...]
[ExcludeFromSelect.ntia64=device-identification-string[,device-identification-string] ...]
[CopyFilesOnly=device-identification-string[,device-identification-string] ...]
[InteractiveInstall=device-identification-string[,device-identification-string] ... ]
 
 

A ControlFlags section identifies devices for which Setup should take certain unique actions during installation.

Entries and Values

device-identification-string
Identifies a hardware ID or compatible ID that has been specified in a per-manufacturer INF Models section. Each string must be separated from the next with a comma (,).
ExcludeFromSelect
Removes all (if * is specified) or the specified list of devices from certain user interface displays, from which a user is expected to select a particular device for installation.

For the NT-based operating system, the specified devices will not be displayed by the Add Hardware Wizard, but will be displayed by the Found New Hardware and Hardware Update wizards.

For Windows 9x/Me, the specified devices will not be displayed by any device selection wizard.

To exclude a set of OS-incompatible or platform-incompatible devices from this display, one or more ExcludeFromSelect entries can have the following case-insensitive extensions appended:

.nt
Do not display these devices on computers running Windows 2000 or later.
.ntx86
Do not display these devices on x86-based computers running Windows 2000 or later.
.ntia64
Do not display these devices on IA-64-based computers running Windows XP or later.

For more information about how to use the system-defined .nt, .ntx86, and .ntia64 extensions, see Creating INF Files for Multiple Platforms and Operating Systems.

CopyFilesOnly
Installs only the INF-specified files for the given devices because the device hardware is not accessible or available yet. This entry is rarely used. However, it can be used to preinstall the drivers of a device for which the card will later be seated in a particular slot that is currently in use. For example, if a device currently seated in the particular slot is necessary to transfer INF-specified files to the target, the INF would have this entry.
InteractiveInstall
Forces the specified list of devices to be installed in a user's context. Each line can specify one or more hardware IDs or compatible IDs and there can be one or more lines.

This entry is optional. The preferred way to install devices is to omit this entry and allow Setup to install the device in the context of a trusted system thread, if possible. However, if a device absolutely requires a user to be logged in when the device is installed, include this entry in the device INF. This entry is not supported on Windows 9x systems.

Comments

Typically, a ControlFlags section has one or more ExcludeFromSelect entries to identify devices that are listed in the per-manufacturer INF Models section, but which should not be displayed to the end user as options during manual installations.

The system's Add Hardware wizard builds a list of installable devices by searching through all available INF files. It extracts information about models/devices from each of these INF files and displays this information to the end user, unless an INF overrides this behavior by suppressing the display of one or more models/devices in that INF's ControlFlags section.

Listing a device's hardware ID or compatible ID in an ExcludeFromSelect entry removes it from the display shown to the end user. Specifying * (an asterisk) for the ExcludeFromSelect value removes all devices/models defined in the INF file from this user-visible list.

An INF writer should use the InteractiveInstall sparingly and only in the following situations:

INF files that install exclusively PnP devices can have a ControlFlags section unless they set the NoInstallClass value entry in their respective SetupClassGUID registry keys to TRUE, as described in the reference for the INF ClassInstall32 section.

In the future, WHQL might not grant the Windows Logo to devices whose INF files include InteractiveInstall entries.

Example

This example of the ControlFlags section in the system mouse class installer INF suppresses the display of devices/models that cannot be installed on NT-based x86 platforms.

[ControlFlags]
; Exclude all bus mice and InPort mice for x86 platforms
ExcludeFromSelect.ntx86=*PNP0F0D,*PNP0F11,*PNP0F00,*PNP0F02,*PNP0F15
; Hide this entry always
ExcludeFromSelect=UNKNOWN_MOUSE

The following INF file fragment shows two devices: one that is fully PnP-capable and requires no user intervention during installation and another that requires its own driver and cannot use any other driver. Specifying InteractiveInstall for the second device forces Setup to install this device in a user’s context (a user with administrative rights), including prompting the user for the location of the driver files (INF file, driver file, and so on) as required.

; ...
[Manufacturer]
%Mfg% = ModelsSection

[ModelsSection]
; Models section, with two entries
%Device1.DeviceDesc% = Device1.Install, \
  PCI\VEN_1000&DEV_0001&SUBSYS_00000000&REV_01
%Device2.Device.Desc%    = Device2.Install, \
  PCI\VEN_1000&DEV_0001&SUBSYS_00000000&REV_02

[ControlFlags]
InteractiveInstall = \
  PCI\VEN_1000&DEV_0001&SUBSYS_00000000&REV_02
; ...

See Also

ClassInstall32, Manufacturer, Models