powered by CADENAS

Manual

Manual

2.2.5.3.2. Key "Material": Use input value as Fallback

The following syntax with "TranslateStringInGlobalOptionArrayDef" is an improvement.

If the material cannot be found in the [MatMap] block of the configuration file, then the input value is used as default. The old function (without „Def“) ignores the input value.

Example:

"aluminium" be the input value. If the function cannot find this value in the [MatMap] block, then the enhanced "Def" function passes "aluminium" to the CAD system. If the value is available in the material table of the CAD, it will use the value. The old function by contrast only returns an empty line.

  • Without macro

    ?context.TranslateStringInGlobalOptionArrayDef("MATMAP","",GetObject("iface.
     calcnameservice").start(0).Format("<CLASSPROP(cns,CNSPHYPROP,CNSMAT)>").value(),GetObject
     ("iface.calcnameservice").start(0).Format("<CLASSPROP(cns,CNSPHYPROP,CNSMAT)>").value())

  • With macro

    ?context.TranslateStringInGlobalOptionArrayDef("MATMAP","",_FORMAT_0("<CLASSPROP
    (cns,CNSPHYPROP,CNSMAT)>").value(),_FORMAT_0("<CLASSPROP(cns,CNSPHYPROP,CNSMAT)>").value())