RegWrite Method |
Description
Creates a new key, adds another value-name to an existing key (and assigns it a value), or changes the value of an existing value-name.
PowerBASIC Syntax
Arguments
Remarks
Specify a key-name by ending strName with a final backslash. Do not include a final backslash to specify a value name. The RegWrite method automatically converts the parameter anyValue to either a string or an integer. The value of vType determines its data type (either a string or an integer). The options for vType are listed in the following table.
Note. The REG_MULTI_SZ type is not supported for the RegWrite method.
Tip RegWrite will write at most one DWORD to a REG_BINARY value. Larger values are not supported with this method.
Fully qualified key-names and value-names are prefixed with a root key. You may use abbreviated versions of root key names with the RegWrite method. The five root keys are listed in the following table.
The four possible data types you can specify with vType are listed in the following table.
Example [PowerBASIC]
#INCLUDE "WSHOM.INC"
DIM pWsh AS IWshShell DIM
vValue AS VARIANT pWsh
= NEWCOM "WScript.Shell"
|