Skip to content

Reg_SetMultiString

Sets the value of a registry variable of type multistring (REG_MULTI_SZ). If the key doesn’t exist, it’s created. The existing content of the variable is replaced. To add strings to the existing content, use Reg_UpdateMultiString.

Reg_SetMultiString(sHandle, sKey, sVariable, vValue) as Boolean

Registry hive, for example HKLM. For all accepted values, see Registry Functions.

Subkey path

Name of variable to contain the value

Array of strings. Empty elements are skipped, and spaces at the start and end of each element are removed. If vValue isn’t an array, the function returns FALSE.

Redim aTmp(2)
aTmp(0) = "Skanderborg"
aTmp(1) = "Taastrup"
aTmp(2) = "Copenhagen"
If bStatus Then bStatus = Reg_SetMultiString("HKLM", "Software\KeyName", "ValueName", aTmp)

Scripting Guidelines

Registry Functions Constants Package Property Variables