The WinReplaceObjectClass function replaces a registered class with another registered class. If fReplace is FALSE, pOldClassName will revert back to its original definition.
#define INCL_WINWORKPLACE
#include <os2.h>
PSZ pOldClassName; /* Pointer to class name. */
PSZ pNewClassName; /* Pointer to new class name. */
BOOL fReplace; /* Function replacement flag. */
BOOL rc; /* Success indicator. */
rc = WinReplaceObjectClass(pOldClassName,
pNewClassName, fReplace);