Macro expression $.cfgfile
This macro expression represents the value stored in the configuration file (
XML or
INI). See:
XML and INI configuration files structure description for $.cfgfile macro expression
Syntax:
$.cfgfile("id","value")
id = the compound value identifier (e.g. "a/b/c")
value = (optional) the backup value in case the referred value is not found
Obsolete syntax of macro expression:
$cfgfile:id,value
Example:
1) $.cfgfile("config/data/webportnumber",0)
- Obtains the value /data/webportnumber from the configuration file referred with the config identifier.
2) $.cfgfile("config/data/webportnumber",80)
- Obtains the value /data/webportnumber from the configuration file registered with config identifier. If the value is not found in the file, then the backup value 80 is returned.
3) $.cfgfile("config/data/boiler1/webportnumber",0)
- Obtains the value of /data/boiler1/webportnumber from configuration XML file registered with config identifier. The expression allows to read the value from arbitrary hierarchical level (the boiler1 level is extra here).
Configurators in extended value editor:
Value identifier | Specifies the compound value identifier, e.g.: config/data/portnumber. |
Enter substitutional value | It is used for entering substitutional value that will be used in case the referred value is not found. |
The backup value | Specifies the substitutional value |
---|