Print this page

Section 6. Sort elements from a Package or an Element by Object Id

sort by object id - creation order

This help article explains how to use eaUtils Sort By Object ID feature on the elements contained in a package or element. Object ID refers to the unique identifier for any element created in EA, with an incremented value matching the creation order e.g. 1, 2, 3... 

This feature runs on a package or an element selected from the Project Browser (it can also be run on a package tree, click here for more information).

Sort elements within a package by object id (creation order)

In the following example, classes have been created in the order matching their suffix value (e.g. -1, -2, -3, etc.).

 eaUtils addin sparx enterprise architect sort by creation object id

Right click on the package where elements need to be sorted > Extensions > eaUtils > Project Browser: sort elements.

sparx enterprise architect sort elements in browser addin

In the following dialog window, select Object ID as the sorting option and confirm that you would like to proceed.

Note: eaUtils sort by settings are displayed. The settings can be opened and modified if needed.

eautils addin sort by object id Sparx EA script API

Once completed, the following window is displayed:

The new sorting order is visible in Enterprise Architect project browser as illustrated below:

Sparx Enterprise Architect sorting addin