IComponent::QueryDataObject method (mmc.h)
The IComponent::QueryDataObject method returns a data object that can be used to retrieve context information for the specified cookie.
Syntax
HRESULT QueryDataObject(
[in] MMC_COOKIE cookie,
[in] DATA_OBJECT_TYPES type,
[out] LPDATAOBJECT *ppDataObject
);
Parameters
[in] cookie
A value that specifies the unique identifier for which the data object is required. When called for virtual list items, which do not have cookies, this parameter is set to the item list index.
[in] type
A value that specifies the data object as one of the following.
CCT_SCOPE = 0x8000
Data object for the scope item.
CCT_RESULT = 0x8001
Data object for the result item.
CCT_SNAPIN_MANAGER = 0x8002
Data object for the Snap-In Manager context.
CCT_UNINITIALIZED = 0xFFFF
Data object has an invalid type.
These constants are members of the DATA_OBJECT_TYPES enumeration.
[out] ppDataObject
A pointer to the address of the returned data object.
Return value
This method can return one of these values.
Remarks
These data objects can be passed to the same snap-in or to extension snap-ins that require them. Some of the MMC interfaces that can use this data object are IComponent, IComponentData, IContextMenuProvider, IExtendContextMenu, IExtendPropertySheet2, and IPropertySheetProvider.
Requirements
Requirement | Value |
---|---|
Minimum supported client | Windows Vista |
Minimum supported server | Windows Server 2008 |
Target Platform | Windows |
Header | mmc.h |
See also
Feedback
https://aka.ms/ContentUserFeedback.
Coming soon: Throughout 2024 we will be phasing out GitHub Issues as the feedback mechanism for content and replacing it with a new feedback system. For more information see:Submit and view feedback for