EPLAN.EPLAN21.WORKINGSET.MERGE

Contents

Description

Command for creating a new EPLAN 21 working set containing a single project taken from a working set with several subprojects.

The EPLAN.EPLAN21.WORKINGSET.MERGE command is called up via the API functions as specified in the EPLAN 21 API.

Parameters

All parameters have the prefix "EPL_PARAM_WORKINGSET_MERGE_".

ParameterID Type Description
IN_DBHANDLE [IN]
EplHandle

Handle to the main database of the working set that is to be merged to a new working set.
The working set must already be open. (Furthermore, the main database must be locked for exclusive use in the current implementation.)

OUT_DBHANDLE [OUT]
EplHandle

Handle of the main database or working set to be newly created.

DBNAME [IN]
String

Name of the main database or working set to be newly created.

DESCRIPTION [IN]
String

Description of the working set to be newly created.

RESDBNAME [IN]
String

Name of the resource database that is to be used together with the newly created working set.
In principle, this should be the same resource database as the one that was already used in the original working set. However, this is not absolutely necessary as long as the resource database transferred here offers the same resources.

RESDBFLAG [IN]
Boolean

Read-only flag for the resource database.

1: Database is opened read-only.
0: Database is opened read-write (default).

MACRODBNAME [IN]
String

Name of the macro database that is to be used together with the newly created working set.

MACRODBFLAG [IN]
Boolean

Read-only flag for the macro database.

1: Database is opened read-only.
0: Database is opened read-write (default).

DEVICEOPTION [IN]
String

Device options parameter of the merging process.

0: Renumber DT always
1: Renumber DTs if needed
2: Create Xrefs
3: Create Xrefs and rebook

RUNDEVICENUMBERING [IN]
Boolean

Renumber flag for DT:

1: DTs are renumbered
0: DTs are not renumbered (default)

RUNWIRENUMBERING [IN]
Boolean

Renumber flag for wiring:

1: Wiring is renumbered
0: Wiring is not renumbered (default)

RUNREPORTGENERATOR [IN]
Boolean

Re-generate flag for forms:

1: Forms are re-generated
0: Forms are not re-generated (default)

REMOVEDUPLICATEREPORTS [IN]
Boolean

Remove flag for duplicate forms:

1: Duplicate forms are removed
0: Duplicate forms are not removed (default)

ERR_COUNT [OUT]
Integer

Number of messages/warnings/errors that occurred

ERR_COMMENT [OUT,INDEX]
String

General description of the message.

ERR_STATUS [OUT,INDEX]
String

Status of the message.

ERR_PROJECT [OUT,INDEX]
String

Name of the (sub)project to which the message refers.

ERR_DT [OUT,INDEX]
String

DT of the element to which the message refers.

ERR_XREF [OUT,INDEX]
String

Cross-reference of the element to which the message refers.

ERR_PAGEIDX [OUT,INDEX]
Integer

Index of the page to which the message refers.
This parameter may be empty, should the message not refer to an instantiated element.

ERR_XCOORD [OUT,INDEX]
Integer

X coordinate of the element on this page.
This parameter may be empty, should the message not refer to an instantiated element.

ERR_YCOORD [OUT,INDEX]
Integer

Y coordinate of the element on this page.
This parameter may be empty, should the message not refer to an instantiated element.

Error Messages

The eplExecuteCommand function returns EPL_OK if the a new working set could be created.

If the command fails, eplExecuteCommand returns the value EPL_ERROR. In this case, the error log can contain the following errors:

ErrorID Description
EPL_ERR_WORKINGSET_MERGE_FILE_EXISTS There is already a database existing with the transferred name. You have to specify a new file name so that the command can create a database which results from the merging process.
EPL_ERR_INVALID_ARGUMENT The handle to the database is invalid. EPLAN cannot find an already open working set for this handle, or the transferred database name is empty.
EPL_ERR_WORKINGSET_MERGE_NOTALLOWED A client prevents the generation of a new database.
EPL_ERR_WORKINGSET_MERGE_ILLEGALTARGET The transferred database name is empty.
EPL_ERR_WORKINGSET_MERGE_COPYFAILED EPLAN 21 starts the merging process by copying the entire main database. Should the copying fail, this error message is output.
EPL_ERR_WORKINGSET_MERGE_MASTERPROJECTCOUNT The main database may only contain exactly one (main) project. You may need to remove further projects from the main database, or move subprojects, that are to belong to the same working set, to individual subdatabases. (Note: Subdatabases may also contain several subprojects.)

Reference