SHRegGetIntW function
Reads a numeric string value from the registry and converts it to an integer.
Syntax
int SHRegGetIntW( _In_ HKEY hk, _In_ LPCWSTR szKey, _In_ int nDefault );
Parameters
- hk [in]
-
Type: HKEY
A handle to the registry key that specifies the value to be read.
- szKey [in]
-
Type: LPCWSTR
A pointer to a string value that specifies the name of the value to be read. The string must be null-terminated.
- nDefault [in]
-
Type: int
An int that specifies the value returned if the registry value cannot be retrieved successfully.
Return value
Type: int
Returns the converted string as an int, or the default value specified by nDefault.
Remarks
Prior to Windows 2000 Service Pack 3 (SP3), Windows Server 2003 Service Pack 1 (SP1), and Windows XP, SHRegGetIntW was not exported by name. On those systems you must load it directly from Shlwapi.dll as ordinal 280.
This function is only available in a Unicode version. ANSI is not supported.
Requirements
|
Minimum supported client |
Windows 2000 Professional [desktop apps only] |
|---|---|
|
Minimum supported server |
Windows 2000 Server [desktop apps only] |
|
Header |
|
|
Library |
|
|
DLL |
|
|
Unicode and ANSI names |
SHRegGetIntW (Unicode) |