We recommend using Visual Studio 2017
This documentation is archived and is not being maintained.

IVsHierarchy.SetProperty Method

Sets properties of a specific node or of the hierarchy.

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

int SetProperty(
	uint itemid,
	int propid,
	Object var


Type: System.UInt32
[in] Item identifier of the hierarchy item whose properties are to be set. For a list of itemid values, see VSITEMID.
Type: System.Int32
[in] Identifier of the hierarchy property. For a list of propid values, see __VSHPROPID.
Type: System.Object
[in] Variant that contains property information.

Return Value

Type: System.Int32
If the method succeeds, it returns S_OK. If it fails, it returns an error code.

COM Signature

From vsshell.idl:

HRESULT IVsHierarchy::SetProperty(
   [in] VSITEMID itemid,
   [in] VSHPROPID propid,
   [in] VARIANT var