.. _Add from Template:

Add from Template
=================


With this feature you can generate code from a single template file (or a folder containing templates) and add it to an existing project.

To access the :guilabel:`Add from Template Wizard` go to :menuselection:`Navigator --> right click on a ''Target'' folder inside a project --> New --> Add from Template`
.. figure:: ../../images/common/template-comp-navigator-menu.png

The next step is to browse for the templates source folder (by default, is the last path used), then click :guilabel:`Next`. 

.. figure:: ../../images/common/template-components-wizard-paths.png

From the :guilabel:`Templates` panel > select the files/folders you want to add to :guilabel:`Target`. In the :guilabel:`Attributes` panel, you can modify the replacement variables by typing a new value or by selecting one from the history. The :guilabel:`Target` panel is used for preview - it shows where the selected files will be placed in the project and signals if there is a *duplicate file* error (if the file you want to add already exists in the target folder).

.. figure:: ../../images/common/template-components-wizard-main.png


