User Tools

Site Tools


xmlscripting-en

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revisionPrevious revision
Next revision
Previous revision
xmlscripting-en [2025/11/25 11:13] rjversluisxmlscripting-en [2025/12/30 08:54] (current) – [Commands] rjversluis
Line 420: Line 420:
  \\  \\
 ====set==== ====set====
-With the set statement a variable can be used to set the attribute text or integer value, depending of setint, of a certain object.\\+With the set statement a variable can be used to set the attribute of a certain object to the text value or integer value of that variable, depending of ''setint''.\\
 <code xml> <code xml>
   <set vr="var1" table="waybilllist" id="%oid%" set="cartype" setint="false"/>   <set vr="var1" table="waybilllist" id="%oid%" set="cartype" setint="false"/>
 </code> </code>
 +^ XMLScript example code of using "setint" ^ explanation ^
 +| <vr id="vr_red" text="255" value="**0**"/> \\ <vr id="vr_green" text="**255**" value="0"/> \\ <vr id="vr_blue" text="255" value="**0**"/> | prepare the RGB values |
 +| <set vr="vr_red" table="txlist" id="tx_rgb" set="bgred" setint="**true**"/> \\ <set vr="vr_green" table="txlist" id="tx_rgb" set="bggreen" setint="**false**"/> \\ <set vr="vr_blue" table="txlist" id="tx_rgb" set="bgblue" setint="**true**"/> | use the RGB value [**0,255,0**] \\ to show the background in color "green" |
  \\  \\
 To set a value of a sub node: To set a value of a sub node:
Line 541: Line 544:
 | Action control | actionctrl |  | | The id in the actionctrl is a reference to an existing action. Condition child nodes may be added. | | Action control | actionctrl |  | | The id in the actionctrl is a reference to an existing action. Condition child nodes may be added. |
 | Operator | operator | emptycar, loadcar, addcar, leavecar | | In the carids attribute a list of cars must be specified. | | Operator | operator | emptycar, loadcar, addcar, leavecar | | In the carids attribute a list of cars must be specified. |
-| System | sys | All https://wiki.rocrail.net/rocrail-snapshot/rocrail/wrapper-en.html#sys | |+| System | sys | All https://wiki.rocrail.net/rocrail-snapshot/rocrail/wrapper-en.html#sys | | add informall="true" for send commands to all CS |
 | Automat | auto | All https://wiki.rocrail.net/rocrail-snapshot/rocrail/wrapper-en.html#auto | | | Automat | auto | All https://wiki.rocrail.net/rocrail-snapshot/rocrail/wrapper-en.html#auto | |
 | Car | car | empty, loaded, maintenance, assignwaybill, resetwaybill, loco & function | empty, loaded, maintenance, cartype, location | | %%<car id="test" cmd="assignwaybill" waybill="testbill"/>%% | | Car | car | empty, loaded, maintenance, assignwaybill, resetwaybill, loco & function | empty, loaded, maintenance, cartype, location | | %%<car id="test" cmd="assignwaybill" waybill="testbill"/>%% |
xmlscripting-en.1764065610.txt.gz · Last modified: 2025/11/25 11:13 by rjversluis