Skip to content

ReadString - cApplication

Reads string data from the Windows registry

Type: Function
Return Data Type: String

Parameters

Parameter Type Description
sSubKey String The name of the Subkey to read the Value from
sValueName String The name of the Value to read data from
sDefault String If the Value could not be read, then the function will return the passed in value

Syntax

Function ReadString String sSubKey String sValueName String sDefault Returns String

Call Example

Get ReadString sSubKey sValueName sDefault to StringVariable

Description

Use the ReadString function to read string data from the Windows Registry. The base key that will be used is that returned by RegistryKeyString and you can specify a further subkey using the sSubKey parameter.

If you attempt to read a non-existent value, an error will be generated. Before trying to read a value, you should ensure that it exists using the ValueExists function.

Return Value

Data read from the Registry, or the passed in value if no value is found.