This documentation is archived and is not being maintained.

Package.Microsoft.VisualStudio.Shell.Interop.IVsPackage.GetAutomationObject Method

Visual Studio 2005

This method supports the VSIP infrastructure and is not intended to be used directly from your code.

Gets an automation-friendly object for this package.

This method is not CLS-compliant.  

Namespace: Microsoft.VisualStudio.Shell
Assembly: Microsoft.VisualStudio.Shell (in

int IVsPackage.GetAutomationObject (
	string propName,
	out Object auto
J# supports the use of explicit interface implementations, but not the declaration of new ones.
JScript does not support passing value-type arguments by reference.



String containing the automation property name.


[out] Returns the automation object.

Return Value

If the method succeeds, S_OK, otherwise an error code.

The default implementation will return auto as a null reference (Nothing in Visual Basic) if propName is a null reference (Nothing in Visual Basic), indicating that there is no default automation object. If propName is non-a null reference (Nothing in Visual Basic), it will walk the metadata attributes searching for an options page that has a name of the format: <Category>.<Name>. If the options page has this format and indicates that it supports automation, its automation object will be returned.