IShellFolderCompareIDs Method

Determines the relative order of two file objects or folders, given their item identifier lists.

Definition

Namespace: DevCase.Win32.Interfaces
Assembly: DevCase.net48 (in DevCase.net48.dll) Version: 6.0.0.0 (6.0)
XMLNS for XAML: Not mapped to an xmlns.
[PreserveSigAttribute]
HResult CompareIDs(
	IntPtr lParam,
	PIDL pidl1,
	PIDL pidl2
)

Parameters

lParam  IntPtr
A value that specifies how the comparison should be performed.

The lower sixteen bits of lParam define the sorting rule.

Most applications set the sorting rule to the default value of zero, indicating that the two items should be compared by name. The system does not define any other sorting rules.

Some folder objects might allow calling applications to use the lower sixteen bits of lParam to specify folder-specific sorting rules. The rules and their associated lParam values are defined by the folder.

When the system folder view object calls CompareIDs(IntPtr, PIDL, PIDL), the lower sixteen bits of lParam are used to specify the column to be used for the comparison.

The upper sixteen bits of lParam are used for flags that modify the sorting rule. The system currently defines these modifier flags.

pidl1  PIDL
A pointer to the first item's ITEMIDLIST structure. It will be relative to the folder.

This ITEMIDLIST structure can contain more than one element; therefore, the entire structure must be compared, not just the first element.

pidl2  PIDL
A pointer to the second item's ITEMIDLIST structure. It will be relative to the folder.

This ITEMIDLIST structure can contain more than one element; therefore, the entire structure must be compared, not just the first element.

Return Value

HResult
If this method is successful, the CODE field of the HResult contains one of the following values.

If this method is unsuccessful, it returns a COM error code.

See Also