This functionality is only available for certain module packages.

You are here: Tutorial > GRAPH2D discipline > Commands for inserting room components (RoomComponent) from the project tree

Commands for inserting room components (RoomComponent) from the project tree

For every device and the person, a command is required in each case, which is executed upon dragging a component from the project tree into the diagram.

  1. Extend the configuration for the commands with the last seven lines.
<!-- Commands -->
<!-- Commands to create nodes out of the project tree -->
<command xsi:type="createNodeForInstance" src="=isInstanceOf('IT_ModularSystem.Buildingcomponents.Floor')" id="add_Floor" />
<command xsi:type="createNodeForInstance" src="=isInstanceOf('IT_ModularSystem.Buildingcomponents.Room')" id="add_Room" />
<command xsi:type="createNodeForInstance" src="=isInstanceOf('IT_ModularSystem.Roomcomponents.PC')" id="add_PC" />
<command xsi:type="createNodeForInstance" src="=isInstanceOf('IT_ModularSystem.Basic.LAN_Jack')" id="add_LAN_Jack" />
<command xsi:type="createNodeForInstance" src="=isInstanceOf('IT_ModularSystem.Roomcomponents.Telephone')" id="add_Telephone" />
<command xsi:type="createNodeForInstance" src="=isInstanceOf('IT_ModularSystem.Roomcomponents.Printer')" id="add_Printer" />
<command xsi:type="createNodeForInstance" src="=isInstanceOf('IT_ModularSystem.Roomcomponents.2wayLANJack')" id="add_2wayLANJack" />
<command xsi:type="createNodeForInstance" src="=isInstanceOf('IT_ModularSystem.Roomcomponents.5waySwitch')" id="add_5waySwitch" />
<command xsi:type="createNodeForInstance" src="=isInstanceOf('IT_ModularSystem.Roomcomponents.Worker')" id="add_Worker" />
  1. Save the diagram configuration ([Ctrl] + [S]).