The internal process described below always reference the selection for which placing is started.
Determining the suitable macro
First the most suitable macro is determined from the macro files specified at the parts. In the process EPLAN only takes into consideration macros of the target representation type, i.e. the representation type of the opened page, and searches for a macro that covers as many functions / function templates of the current selection as possible. If several macros are available that suit to a similar extent, the macro that contains the least further functions of the same device is selected.
Determining the suitable device in the macro
If several devices exist in the macro, the one that suits best is determined. In the case of identical ones the graphically first one is used.
Assignment of functions or function templates in the project to functions in the macro
For this assignment the properties that a corresponding function template can have are compared. Those functions are assigned with priority are not yet placed in the target representation type. Next those pairings are first assigned that have the greatest agreement and then those with a lower number of agreements.
This means that those pairs that have the same connection point designations find each other with priority. Subsequently, however, those are also assigned that only have a suitable function definition.
If not all the functions in the macro have found a counterpiece, the selection is extended to the entire device and the rest is assigned.
Functions from the macro that do not have an assignment at the end are inserted additionally. If functions of the previously determined device are found, the same DT is assigned to them as to the functions that could be assigned: the device is not split up.
Assignment of the data
A difference is made between graphical data and function data with regard to the assignment of the data. In this context graphical data are those data that have an influence on the graphics or that depend on the graphical layout (such as symbols, property arrangements, the property DT adoption: Search direction, etc.), while function data are those data that define or describe a function.
All the function data that already exist at the functions in the project or at the function templates overwrite the data in the macro. However, properties that are filled out in the macro are not overwritten by empty properties. This ensures that the function data from the macro are retained.
All the graphical information, by contrast, originate from the macro.
Placing connected functions as a template group
In the parts management function templates of associated functions can be combined as a logical unit. This is done by entering a uniform number or designation in the column Template group (multi-line) of the function templates tab.
All the connected functions can be placed together out of the device navigator by grouping to a template group. If one of these functions is marked in the navigator, all the functions of the template group are placed at the same time - together with the part stored at the macro. This joint placing is only possible on multi-line pages (page type "Schematic multi-line" and "Fluid power schematic").
If, therefore, you want to use a macro in order to add further functions to a device in the project, you have to insert the macro in the graphical editor and customize the DT correspondingly.