WinXRegistry_WriteString


WinXRegistry_WriteString (hKey, subKey$, value$, SECURITY_ATTRIBUTES sa, int)

Writes an integer to the registry

Parameter Description
hKey The handle to the key to read from. See remarks for more on this parameter
subKey The subkey to read from, remember to double up the backslashes
value$ The value to read from
SECURITY_ATTRIBUTES sa The security attributes for the key if it needs to be created. You can create this with the WinXNewACL function and $$ACL_REG_STANDARD as the parameter
buffer$ The string to write into the registry

Returns

$$TRUE on succcess or $$FALSE on fail

Remarks

The hKey parameter can the the handle of an open key, or, more likely, one of these open keys: $$HKEY_CLASSES_ROOT, $$HKEY_CURRENT_USER, $$HKEY_LOCAL_MACHINE, $$HKEY_USERS.

If the subkey or value does not exist, it will be created using the specified security attributes.

Examples

' Write the string "Hello" into the registry
WinXRegistry_WriteString ($$HKEY_LOCAL_MACHINE, "SOFTWARE\\myapp", "aString", WinXNewACL($$ACL_REG_STANDARD, $$TRUE), "Hello")

Related Links

WinXNewACL
WinXRegistry_WriteInt
WinXRegistry_WriteBin
WinXRegsitry_ReadString