IVsObjectList.ToggleState(UInt32, UInt32) Method

Definition

Tells the requested tree item to toggle its checked state if it has check boxes.

C++/WinRT
int ToggleState(unsigned int index, [Runtime::InteropServices::Out] unsigned int & ptscr);

Parameters

index
UInt32

[in] Specifies the index of the tree list item of interest.

ptscr
UInt32

[out] Pointer to the _VSTREESTATECHANGEREFRESH value.

Returns

If the method succeeds, it returns S_OK. If it fails, it returns an error code.

Implements

Remarks

COM Signature

From vsshell.idl:

cpp#
HRESULT IVsObjectList::ToggleState(  
   [in] ULONG Index,  
   [out] VSTREESTATECHANGEREFRESH *ptscr  
);  

This method returns the state of the given tree list item. The item might have more than one state. The states are taken from the _VSTREESTATECHANGEREFRESH enumeration.

Applies to

Proizvod Verzije
Visual Studio SDK 2015, 2017, 2019, 2022