SetupDiSetDriverInstallParamsA function (setupapi.h)

The SetupDiSetDriverInstallParams function sets driver installation parameters for a driver information element.

Syntax

WINSETUPAPI BOOL SetupDiSetDriverInstallParamsA(
  [in]           HDEVINFO              DeviceInfoSet,
  [in, optional] PSP_DEVINFO_DATA      DeviceInfoData,
  [in]           PSP_DRVINFO_DATA_A    DriverInfoData,
  [in]           PSP_DRVINSTALL_PARAMS DriverInstallParams
);

Parameters

[in] DeviceInfoSet

A handle to a device information set that contains a driver information element that represents the driver for which to set installation parameters.

[in, optional] DeviceInfoData

A pointer to an SP_DEVINFO_DATA structure that specifies a device information element in DeviceInfoSet. This parameter is optional and can be set to NULL. If this parameter is specified, SetupDiSetDriverInstallParams sets the driver installation parameters for the specified device. If this parameter is NULL, SetupDiSetDriverInstallParams sets driver installation parameters for DeviceInfoSet.

[in] DriverInfoData

A pointer to an SP_DRVINFO_DATA structure that specifies the driver for which installation parameters are set. If DeviceInfoData is specified, this driver must be a member of a driver list that is associated with DeviceInfoData. If DeviceInfoData is NULL, this driver must be a member of the global class driver list for DeviceInfoSet.

[in] DriverInstallParams

A pointer to an SP_DRVINSTALL_PARAMS structure that specifies the new driver install parameters.

Return value

The function returns TRUE if it is successful. Otherwise, it returns FALSE and the logged error can be retrieved by a call to GetLastError.

Remarks

Note

The setupapi.h header defines SetupDiSetDriverInstallParams as an alias that automatically selects the ANSI or Unicode version of this function based on the definition of the UNICODE preprocessor constant. Mixing usage of the encoding-neutral alias with code that is not encoding-neutral can lead to mismatches that result in compilation or runtime errors. For more information, see Conventions for Function Prototypes.

Requirements

Requirement Value
Minimum supported client Available in Microsoft Windows 2000 and later versions of Windows.
Target Platform Desktop
Header setupapi.h (include Setupapi.h)
Library Setupapi.lib

See also

SetupDiGetDriverInstallParams