Using POSTMSG to minimize/restore a window

  • This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn more.
Aug 19, 2008
146
0
#1
Because I came here looking for how to do this, and just in case I need to know again someday :D.

Reference:
#define SC_MINIMIZE 0xF020 /* 61472 */
#define SC_RESTORE 0xF120 /* 61728 */

#define WM_SYSCOMMAND 0x0112 /* 274 */

Command line:
<c:\> POSTMSG "*Notepad*" 274 61472

<c:\> POSTMSG "*Notepad*" 274 61728</c:\></c:\>