ListEditRelatedItemsWithFilter client API - SmartPlant Foundation - IM Update 46 - Help - Hexagon

SmartPlant Foundation Help

Language
English
Product
SmartPlant Foundation
Search by Category
Help
SmartPlant Foundation / SDx Version
10
SmartPlant Markup Plus Version
10.0 (2019)
Smart Review Version
2020 (15.0)

The ListEditRelatedItemsWithFilter client API can be used to create a method to return a set of objects related to the selected object for editing. The related objects are returned in a List Edit control and can be filtered to include only objects of a particular type.

Argument

Description

Parameter 1

Title

Parameter 1 default

None

Parameter 1 description

The title used on the List Edit control when it is displayed. The number of items is appended to it.

Parameter 1 type

String

Parameter 2

ClassDefForNewRows

Parameter 2 default

None

Parameter 2 description

The name of the class definition to use when creating new rows. If this is not present, the creation of new rows is disabled.

Parameter 2 type

String

Parameter 3

DeleteAction

Parameter 3 default

None

Parameter 3 description

The action to take place on deletion of a row. Possible values are Delete, Terminate, or blank. If this value is not specified, the Delete option is disabled from the shortcut menu and from the Delete key.

Parameter 3 type

String

Parameter 4

ColumnSetName

Parameter 4 default

None

Parameter 4 description

The name of the column set to use when displaying the data. This defines the columns, the sort order, and so on.

Parameter 4 type

String

Parameter 5

Reldef for related items

Parameter 5 default

None

Parameter 5 description

Relationship definition (prefixed with +/-) to use when populating the List Edit control.

Parameter 5 type

String

Parameter 6

Related items filter

Parameter 6 default

None

Parameter 6 description

Query filter – Property comparison

Specifies which objects to include in the filtered results. The string should consist of a set of values, separated with a tilde (~), for interface name, attribute name, and property UID.

For example, IDEVTag~DEVTagType~=~{24D3D468-67E7-4DB9-BB2C-2AF2743E8158}

Parameter 6 type

String

Parameter 7

QueryMethod

Parameter 7 default

None

Parameter 7 description

The UID of the query method to use. If this is present, the software displays the Query for button, which contains all the information required to find an item. If not present, the button is not displayed.

Parameter 7 type

String

Parameter 8

QueryMethodButtonCaption

Parameter 8 default

None

Parameter 8 description

The caption appended to the button that is enabled with parameter 7 (if present). This is needed for searching the related items.

Parameter 8 type

String

Parameter 9

Apply Filter to Query

Parameter 9 default

None

Parameter 9 description

This property should be set to TRUE to use filter criteria provided in parameter 6.

If the property is set to FALSE, the filter criteria set in parameter 6 is ignored.

Parameter 9 type

Boolean

No delivered method uses this client API, but the following example illustrates how you can use this client API and the List Edit control to edit Electrical Equipment tags related to a document:

  1. Launch a List Edit control from the shortcut menu of the document object.

  2. Create the method for launching the List Edit control using this API and setting parameter 5 to use a relationship definition to navigate to tags related to the documents.

  3. Set parameter 9 to True and parameter 6 to navigate to the specific tag category Electrical Equipment.

    If parameter 9 is set to False, then all the tags related to the document are returned, regardless of the tag category specified in parameter 6.