Skip to end of metadata
Go to start of metadata

Using the scripting language you can search and have a more fine-grained result. Extra conditions can be added like looking for certain objects that are somewhat similar in wording ordered by specific object types.

// Add the types in scope to this list, or leave it empty to check all types:

// selectedTypes = List();
selectedTypes = List( "ApplicationComponent", "ApplicationDataObject" );

// Ignore case?
caseInsensitive = true;

// The number of characters (from the start of the name) that need to match:
matchingLength = 4;

// Output is sent to the messages window (use the buttons on the window to highlight the objects),
// but can also be sent to a table output:
outputToTableAlso = true;

// If no types specified, determine all types present in the model package:
if ( selectedTypes.empty() ) {
	forall List( "AbstractCompound", "AbstractElement" ) obj in modelpackage {
		typeName = obj.type().name();
		if ( !selectedTypes.contains( typeName ) ) {
			selectedTypes.add( typeName );

// For each type, find all objects and collect those that match:
forall selectedType in selectedTypes {
	matchFound = false;
	possibleMatches = Index();
	forall selectedType obj in modelpackage {
		stub = 1, matchingLength );
		if ( caseInsensitive ) {
			stub = stub.toLowerCase();
		objs = possibleMatches.valueFor( stub );
		if ( objs.isUndefined() ) {
			objs = Set( obj );
		else {
			objs.add( obj );
			matchFound = true;
		possibleMatches.add( stub, objs );
	if ( matchFound ) {
		simpleType = selectedType.contains( ":" ) ? selectedType.trim().split( ":" )[2] : selectedType;
		forall stub, objs in possibleMatches {
			if ( objs.size() > 1 ) {
				message format( "%s '%s' objects starting with '%s': %s", objs.size(), translate( simpleType ), stub, objs ), objs;
				if ( outputToTableAlso ) {
					outputl format( "%s '%s' objects starting with '%s':", objs.size(), translate( simpleType ), stub ), objs;

The script has some customization options like:

  • Adding additional filters to the script like ApplicationCollaboration or ApplicationDataObject to further specify the objects.
  • Comparing case-insensitive (set caseInsensitive to true).
  • Increasing or decreasing search results by changing the MatchingLength. The higher this number, the less results you will get.
  • Saving the script as viewpoint and using during housekeeping or maintenance on your model package.
  • It outputs to the messages window by default, but can also output to a table (set outputToTableAlso to true). The Messages window has the advantage that by clicking the buttons on the message, the duplicate objects are highlighted in the model browser.

In the Query editor, use output type "Table" to export the results to Excel for further analysis.


Run the script on the objects below:

The output will be:

Clicking on any of the objects will open that object both in the model browser and view.