NdisWriteConfiguration writes a caller-supplied value for a specified entry into the registry.
VOID
NdisWriteConfiguration(
OUT PNDIS_STATUS Status,
IN NDIS_HANDLE ConfigurationHandle,
IN PNDIS_STRING Keyword,
IN PNDIS_CONFIGURATION_PARAMETER ParameterValue
);
typedef struct _NDIS_CONFIGURATION_PARAMETER {
NDIS_PARAMETER_TYPE ParameterType;
union {
ULONG IntegerData;
NDIS_STRING StringData;
} ParameterData;
} NDIS_CONFIGURATION_PARAMETER, *PNDIS_CONFIGURATION_PARAMETER;
The members of this structure can contain the following data:
For Windows 2000 and later drivers, this is a counted Unicode string.
For Windows 2000 and later drivers, such a string contains Unicode characters.
Declared in Ndis.h. Include Ndis.h.
If an entry of the same name as at Keyword already exists under the opened registry key, NdisWriteConfiguration replaces its current value with the caller-supplied value. Otherwise, NdisWriteConfiguration adds a new value entry with the given name and supplied value to the registry.
In the configuration registry of Windows 2000 and later versions, an NDIS keyword is a synonym for a value entry name. Such a name is a counted sequence of Unicode characters, terminated with a NUL.
NdisWriteConfiguration buffers and copies the caller-supplied string at Keyword and the caller-supplied data specified at ParameterValue. This memory is freed when the driver releases the ConfigurationHandle with NdisCloseConfiguration. The caller of NdisWriteConfiguration is responsible for releasing the buffered string at Keyword and the memory allocated for the NDIS_CONFIGURATION_PARAMETER structure.
As an alternative to calling NdisWriteConfiguration, every NDIS driver can set up configuration information in the registry for itself under the driver’s Parameters key using an installation script.
For more information about setup and installation scripts for Windows 2000 and later versions, see Device Installation Overview.
Callers of NdisWriteConfiguration run at IRQL = PASSIVE_LEVEL.
ANSI_STRING, MiniportInitialize, NdisAnsiStringToUnicodeString, NdisCloseConfiguration, NdisFreeMemory, NdisFreeString, NdisInitAnsiString, NdisInitializeString, NdisInitUnicodeString, NdisOpenConfiguration, NdisOpenConfigurationKeyByIndex, NdisOpenConfigurationKeyByName, NdisOpenProtocolConfiguration, NdisReadConfiguration, NdisUnicodeStringToAnsiString, UNICODE_STRING