Component element

Component element

The component element is selected via this icon:

Component0001

 

Components can be used, if you want to reuse a collection of elements for multiple templates. This can e.g. be used, if you want to define a special header or footer, that should be common for many business documents. The advantage with the component is, that you can easily change such a common component once and immediately change e.g. the company logo or contact information.

 

Important note: The component element is created as a way to share a part of a design template, that you want to reuse across one or more templates. It is not directly possible to create a page element within a component and that reflects the best pratice of the component: It might be possible to drag/move a page element into a component, but this is not how the component should be used. So if you see issues while placing a page element inside a component, the recommendation is to move the page element out of the component and instead e.g. consider to create up to 3 components instead: For the headerbody and footer section of the page element.

 

 

The topics in this section are:

1.How to create a component.

2.How to include a component in a template.

3.How to change (and save) a component.

4.Delete a component from a template

5.Some component tools.

6.How to delete a component from the tenant.

7.How to use a component in header or footer.

8.List of sample/demo components. InterFormNG2 includes a list of sample/demo components, that you can use as reference or use as a basis to build your own components.

 

 

Create a component

To create a new component only a single element can be selected. This single element can e.g. be a container with multiple elements inside.

To create the component you right click on the element e.g. container and select 'Create Component':

 

NG2CreateComponent0001

 

After you have clicked 'Create Component' this window is shown:

 

NG2CreateComponent0002

 

The fields are:

 

Folder

Here you can select a folder or create a new folder for the component with the magnifying glass on the right.

 

Component name

Type a name for the component to be saved.

 

Only inner contents

If this is activated (red - marker on the right), then only elements inside the selected container are moved to the component, and the component is referenced inside the container - like this:

NG2CreateComponent0003

If it deactivated (grey with marker on the left), then the container element itself is moved into the component:

 

NG2CreateComponent0004

When you click 'Create new component' the component is saved as the specified name with the extension .icmp in the selected folder. The output of the template remains the same. After this the component is also listed in the Library.

 

 

Include a component in a template

You can include a component while editing a template in two ways:

 

1.You can click the component icon on the left:

NG2CreateComponent0005

After that you are shown a list of all components and folders containing components. From here you select component a simply drag it to the result view.

You now click this icon to see the layout (element tree structure of the template):

 

NG2Layout0001

 

 

2.You can also select a component to be inserted by clicking the '+' in the middle of the top and click the component icon in the second row:

NG2ComponentInsert0001

 

 

After inserting the component, you can drag (or copy and paste) the reference to the component into another place in the tree structure if needed.

 

Change a component

To change a component you need to include a reference to the component in a template. When you have done that you simply open the component folder and change the contents. This is almost too easy, so take care not to change a component by accident as this will effect all the other templates, that are using this component.

 

To avoid accidental changes you are warned in three ways:

First when you change a component you will see this warning message in the lower left corner:

NG2ComponentChangeWarning001

 

Then a red dot is shown to the right of the changed component in the element list:

 

NG2ComponentChangeWarning002

 

And when you later want to save your changes you are reminded again, if you also changed a component:

 

NG2ComponentSaveWarning001

 

If you want to regret the change of the component, then you should select 'CANCEL' on the window above.

 

 

Delete a component from a template

If you want to remove a component from a template, then you can delete the reference to the component in two ways:

 

1.You can click on the component and then press the <Delete> key on your keyboard.

2.You can also right-click on the component in the element list and then click 'Delete component':

 

NG2Component0005

Please notice, that this Delete Component function only deletes the reference to the component, it does not delete the component from the system.

If you want to delete the component from the system, then you should read this section.

 

 

 

Component tools in the designer

If you right click on a component in the element list, then you will see these options:

 

NG2ComponentTools0001

 

The tools are described below:

 

Unlink

Remove the reference to the component. This works like the 'Delete Component' option above. The component is not delete, but the reference (or link) to the component is deleted. If you really want to delete a component, then you need to do that from the Library.

 

Save

If you have changed a component you can chose to save it now with this option.

 

Save as Copy

Takes a copy of the component and references the new copy. This can e.g. be used, if you want to change a component, but as other templates should still 'see' the original component, you can instead take a copy and use that for this template. Then you can modify the new component without affecting any other templates.

 

Reload

Reloads the component. This can e.g. be used if another user has just changed the component, and you want to see the updated version of the component with the current template.

 

Download

With this option you can save a copy of the component to your local PC e.g. as backup or for copying to another installation.

 

 

The use of a common component is covered in this video:


 



    • Related Articles

    • Table element

      You can use a table element to insert design elements in organized rows and columns. Each cell in the table can be surrounded by a border and/or filled out with a color. You can even create a dynamic table with a row for each detail line in the input ...
    • Multicast workflow component

      The multicast workflow component can be used, if you want to create multiple outputs from a single input file. You e.g. might want to create a PDF file, an email and a print output from a single input XML file. To do that the multicast component can ...
    • Choice workflow component

      The choice workflow component can be used to condition the processing of the files. The choice component can branch out to one or many cases (subtrees) depending on a condition for each case (subtree). When you insert a new choice component it will ...
    • Set Printing properties component

      The set printing properties workflow component is relevant, if you are going to print out on a PCL compatible printer. So if want to use the features below, then you need to ensure, that this is set prior to the merge into PCL. You can also consider ...
    • Choice and join workflow component

      The basic, special Choice and join workflow component is very similar to the Choice component. For the majority of the documentation of the Choice and join you should refer to the choice component as choice and join does the same as the choice ...