This function associates a pointer-conversion procedure with a window.
#define INCL_WINTHUNKAPI /* Or use INCL_WIN, INCL_PM, */ #include <os2.h> HWND hwnd; /* Window handle. */ PFN pthunkpr; /* Pointer-conversion procedure identifier. */ BOOL rc; /* Success indicator. */ rc = WinSetWindowThunkProc(hwnd, pthunkpr);