fgl_setproperty()

 

fgl_setproperty is the same as fgl_getproperty, except that it sets rather than gets values.

The function is used in the following way:

fgl_setproperty ["gui"], type.name, value)

In the above syntax, "gui" refers to the subsystem that the property belongs to. This optional parameter defaults to "gui", so it can be omitted. The type is the element of the subsystem that the property affects; the name is the actual name of the property. Value, which is primarily used when editing properties, can either be the new desired setting when used with fgl_setproperty(), or a specific location/file when used with fgl_getproperty(). If there is no value required in a fgl_getproperty() call, then simply enter two sets of quotation marks.

This function overrides any matching settings specified in a script file.

Other types of properties that you can set are:

·         Registry settings

·         Environment variables

·         System parameters, IP addresses, system name,  host name

·         Script options

·         Any arbitrary user properties

 

Property Type

Property Name

Example

System.registry

Registry key to be read

fgl_setproperty("gui", "system.registry",
"HKEY_LOCAL_MACHINE\\SOFTWARE\\
QUERIX\\Q4GL\\QUERIXDIR")

System.environment

Environment variable name

fgl_setproperty("gui", "system.environment",
"TEMP")

System.network

"Ipaddress"

 

System.network

"hostname"

 

system

"username"

 

user

User property name

fgl_setproperty("gui","user.hello","myoption")