Introduction

The Import Tool can be used to add or update any sub component in a component. This is very useful when you need to add a specific extension which is not an alarm nor an history and you don't want to create a new line for it, create a reference etc.

To create a sub component, you need to define the component to create in the model cell and the name of the component in the name cell.

To update an already existing sub component only the name is required.


Example

A ModbusAsyncDevice named MyDevice is created inside the component described in the row

subcomponent:MyColumnName
 Create/update subComponents
modelnameslot:enabledinfo:{slot('status')}action
modbusAsync:ModbusAsyncDeviceMyDevice


Columns syntax

Add a column with a name using this format: subcomponent:typeSpec or path to a template. Then you can define those following subcolumns

  • model: template to create or change the type of the subComponent (Mandatory only for a creation).
  • name: name of the subComponent (Mandatory for a creation or an update).
  • several info subColumns
  • several slot subColumns
  • several action subColumns

Accepted value

The subcomponent can be created from its TypeSpec, a template or a variable.

  • model:  (by priority during the export) 
    • a variable (associated to a Typespec or a path to a template)

    • a TypeSpec

    • path to a template

  • name: any name
  • info values
  • slot values
  • action values

The value can be wrapped in a variable

IMPORT

You CANNOT have the same subComponent name (including alarm and history extensions) in the same component twice, only the first one will be processed

Create a Sub Component

During the creation of the sub component, a slot named "excelTemplate" with the model value will be added in the sub component.

This value will be used so it can be displayed during the export.

Change the type of an existing Sub Component

If the value in the model cell is different from the value previously saved in the sub component, the sub component will be deleted and a new sub component with the desired type will be created.

Be careful with the model value,

  • ANY DIFFERENCE between the cell and the saved value will trigger the change. All the previous slot values will be lost.
  • if the sub component was not created using excel, importing the sub component with a model value will change the type the sub component in the station. Again, the previous slot values will be lost.

Try it yourself !

Here is the file used in the above import example. Download it, try importing it and see the result.

addSubComponent.xlsx


EXPORT

If there is a value in the "excelTemplate" slot, the value will be exported otherwise, the cell will be left blank.