ICategorizer::CompareCategory method (shobjidl_core.h)
Determines the relative order of two items in their item identifier lists, and hence in the UI.
Syntax
HRESULT CompareCategory(
CATSORT_FLAGS csfFlags,
DWORD dwCategoryId1,
DWORD dwCategoryId2
);
Parameters
csfFlags
Type: CATSORT_FLAGS
A flag that specifies how the comparison should be performed. The parameter should be one of the values in CATSORT_FLAGS.
dwCategoryId1
Type: DWORD
A DWORD that specifies the first category identifier to use in the comparison.
dwCategoryId2
Type: DWORD
A DWORD that specifies the second category identifier to use in the comparison.
Return value
Type: HRESULT
If this method is successful, the CODE field of the HRESULT contains a value that specifies the outcome of the comparison, otherwise it returns a COM error code.
Remarks
The following table shows the values returned in the CODE field of the HRESULT.
Less than zero | The first item should precede the second (dwCategoryId1 < dwCategoryId2). |
Greater than zero | The first item should follow the second (dwCategoryId1 > dwCategoryId2). |
Zero | The two items are the same (dwCategoryId1 = dwCategoryId2). |
Requirements
Requirement | Value |
---|---|
Minimum supported client | Windows XP [desktop apps only] |
Minimum supported server | Windows Server 2003 [desktop apps only] |
Target Platform | Windows |
Header | shobjidl_core.h (include Shobjidl.h) |
DLL | Shell32.dll |
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