The wpclsQueryExtendedCriteria method is called to allow the specified class to specify the extended criteria to be used on a search for instances of this class.
#define INCL_WINWORKPLACE
#include <os2.h>
M_WPObject *somSelf; /* Pointer to the WPObject class object. */
PSZ Title; /* Pointer to the title specification for objects to be searched. */
ULONG ulSearchType; /* Flag indicating type of search to be performed. */
PVOID ExtendedCriteria; /* Pointer to a buffer that contains the class-specific extended search criteria. */
BOOL fSuccess; /* Success indicator. */
fSuccess = wpclsQueryExtendedCriteria(somSelf,
Title, ulSearchType, ExtendedCriteria);