PyIShellFolder.CompareIDs

int = CompareIDs(lparam, pidl1 , pidl2 )

Determines the sorting order of 2 items in shell folder

Parameters

lparam : int

Lower 16 bits specify folder-dependent sorting rules, 0 means to sort by display name. System folder view uses these as a column number.
Upper sixteen bits is used for flags SHCIDS_ALLFIELDS or SHCIDS_CANONICALONLY

pidl1 : PyIDL

Item id list that idenfies an object relative to the folder

pidl2 : PyIDL

Item id list that idenfies an object relative to the folder

Return Value

Returns 0 if items compare equal, -1 if the pidl1 comes first, or 1 if pidl2 comes first