GlobalObject Constructor (Type^, String^)

 

Initializes a new instance of the GlobalObject class.

Namespace:   Microsoft.VisualStudio.Shell.Design
Assembly:  Microsoft.VisualStudio.Shell.Design (in Microsoft.VisualStudio.Shell.Design.dll)

protected:
GlobalObject(
	Type^ objectType,
	String^ objectName
)

Parameters

objectType
Type: System::Type^

The Type of the global object.

objectName
Type: System::String^

A String containing the name of the global object.

Exception Condition
ArgumentNullException

objectType is null.

The GlobalObject constructor is not publicly accessible because global objects are usually created using the GetGlobalObjects method of the GlobalObjectService class. With this mechanism, you can track global objects for type changes, additions, and removals.

This constructor sets the Name property to the objectName parameter. This is the name of the object as it is displayed to the user of the design-time environment, and should follow the usual rules for identifiers. This name is filtered through the System.ComponentModel.Design.Serialization::INameCreationService by the designer to ensure that it conforms to language restrictions.

Return to top
Show: