This function returns the size, in bytes, of a value item in the registry.
GetValueBufferSize (ValueName As String, BufferSize As Long) As Long
Parameters
ValueName
[in] Name of the value to query.
BufferSize
[out] The size, in bytes, of the necessary buffer space to hold the value. For example, a DWORD value will return 4 bytes, while a string value will return the length of the string. For a birany value, the number of bytes will be returned.
Return Value
0: success
1: value name not accessible