VC_ReadProfileString

BOOL
VC_ReadProfileString(
    PVC_PROFILE_INFO
 pProfile,
    PWCHAR ValueName,
    PWCHAR ValueString,
    DWORD ValueLength
   
);

The VC_ReadProfileString function reads the string value associated with the specified value name, under the driver’s \Parameters registry key.

Parameters
pProfile
Address of the VC_PROFILE_INFO structure returned by VC_OpenProfileAccess.
ValueName
Pointer to a UNICODE string identifying the name of a registry value.
ValueString
Pointer to a buffer to receive the requested string value.
ValueLength
Length, in bytes, of the buffer pointed to by ValueString.
Return Value

Returns TRUE if the operation succeeds. If the ValueName string does not exist in the registry, cannot be accessed, is not a REG_SZ (string) type, or if the specified buffer is not large enough to hold the returned string, the function returns FALSE.

Comments

If the operation succeeds, the VC_ReadProfileString function copies the string value into the specified buffer.

The value name and value are read from the registry path HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\DriverName\Parameters, where DriverName is the driver name specified as input to VC_OpenProfileAccess.

See Also

VC_ReadProfile, VC_ReadProfileUser, VC_WriteProfile, VC_WriteProfileUser