Project.GetObjectMatchingID method (Project)

Returns the matching identification name of an object.

Syntax

expression. GetObjectMatchingID( _ObjectType_, _ObjectName_ )

expression A variable that represents a Project object.

Parameters

Name Required/Optional Data type Description
ObjectType Required Long The type of object. Can be one of the PjOrganizer constants.
ObjectName Required String Display name of the object.

Return value

String

Remarks

Use the GetObjectMatchingID method to get the display name in a multilanguage environment that uses Object Matching Identifier (OMID) fields. For more information, see the UseOMIDs property.

Example

The following example gets the Matching ID of a View object with the display name "My Gantt Chart".

MsgBox(ActiveProject.GetObjectMatchingID(pjView, "Gantt Chart"))

Support and feedback

Have questions or feedback about Office VBA or this documentation? Please see Office VBA support and feedback for guidance about the ways you can receive support and provide feedback.