This example shows how the repositioning of a window is recorded in SWP structures with the WinSaveWindowPos call.
#define INCL_WINFRAMEMGR #include <OS2.H> #define COUNT 10 HSAVEWP hsvwp; SWP aswp[COUNT]; ULONG msg; switch(msg){ case WM_ADJUSTFRAMEPOS: WinSaveWindowPos(hsvwp,aswp,COUNT); }