Project.SetObjectMatchingID method (Project)

Sets the matching identification value of an object in the Organizer dialog box, for example to change the view specified by "Gantt Chart".

Syntax

expression. SetObjectMatchingID( _ObjectType_, _ObjectName_, _MatchingID_ )

expression A variable that represents a Project object.

Parameters

Name Required/Optional Data type Description
ObjectType Required Long The type of object, specified by a pjOrganizer constant.
ObjectName Required String Display name of the object.
MatchingID Required String String specifying the matching ID to set.

Example

The following example sets the matching ID of a pjView object type with the display name "Gantt Chart" to "Gantt Chart 1".

ActiveProject.SetObjectMatchingID ObjectType:=pjView, ObjectName:="Gantt Chart", MatchingID:="Gantt Chart 1"

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.