IResultData::ModifyItemState method (mmc.h)
The IResultData::ModifyItemState method enables the snap-in to modify the state of an item.
Syntax
HRESULT ModifyItemState(
[in] int nIndex,
[in] HRESULTITEM itemID,
[in] UINT uAdd,
[in] UINT uRemove
);
Parameters
[in] nIndex
A value that specifies the index of the item whose state is to be modified. This parameter is used only when the itemID parameter is zero. When applied to virtual lists, you must use nIndex and set itemID to zero.
[in] itemID
Unique identifier of the item whose state is to be modified. When applied to virtual lists, set itemID = 0.
[in] uAdd
A value that specifies which Windows list-view state flags can be set. When applied to virtual lists, only focus and select states can be modified. This value can be any valid combination of the following:
LVIS_CUT
The item is marked for a cut-and-paste operation.
LVIS_DROPHILITED
The item is highlighted as a drag-and-drop target.
LVIS_FOCUSED
The item has the focus, so it is surrounded by a standard focus rectangle. Although more than one item can be selected, only one item can have the focus.
LVIS_SELECTED
The item is selected. The appearance of a selected item depends on whether it has the focus and on the system colors used for selection.
[in] uRemove
A value that specifies the list-view item state flags that can be removed. This value can be any valid combination of the preceding Win32 LVIS_* flags shown for the uAdd parameter.
Return value
This method can return one of these values.
Requirements
Requirement | Value |
---|---|
Minimum supported client | Windows Vista |
Minimum supported server | Windows Server 2008 |
Target Platform | Windows |
Header | mmc.h |
DLL | Mmcndmgr.dll |