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 replacement value in case the referred value is not found
Obsolete syntax of the macro expression:
$cfgfile:id,value
Example:
1) $.cfgfile("config/data/webportnumber",0)
- Obtains the /data/webportnumber value from the configuration file referred with the config identifier.
2) $.cfgfile("config/data/webportnumber",80)
- Obtains the /data/webportnumber value 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 /data/boiler1/webportnumber value from XML configuration 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 replacement value | It is used for entering substitutional value that will be used in case the referred value is not found. |
Replacement value | Specifies the replacement value |
---|