Thread: Detecting if a window is minimized

  1. #1
    Banned Yuri's Avatar
    Join Date
    Aug 2005
    Location
    Breukelen, The Netherlands
    Posts
    133

    Detecting if a window is minimized

    Hi.
    I am having trouble to detect something.
    If you want to know if a window is hidden you could use 'IsWindowVisible', easy to use.
    But if you want to know if a window is minimized (and not your own window) it is harder to do and I don't know how.
    I have tried something like this but it wont work:
    Code:
    if ( SendMessage ( FindWindow ( "TheOtherWindowClass", "TheOtherWindowCaption" ), WM_SIZE, ( WPARAM ) SIZE_MINIMIZED, 0 ) )
    Could someone please help me?

  2. #2
    Banned Yuri's Avatar
    Join Date
    Aug 2005
    Location
    Breukelen, The Netherlands
    Posts
    133
    ****, I just found it, I have searched very long on the forums and couldn't find it, now I just found it.
    Code:
    if ( IsIconic ( FindWindow ( "TheOtherWindowClass", "TheOtherWindowCaption" ) ) )
    That will do it, if I just searched longer there wouldn't be need for this thread, a moderator may delete this.

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. WM_CAPTION causing CreateWindowEx() to fail.
    By Necrofear in forum Windows Programming
    Replies: 8
    Last Post: 04-06-2007, 08:23 AM
  2. 6 measly errors
    By beene in forum Game Programming
    Replies: 11
    Last Post: 11-14-2006, 11:06 AM
  3. My Window Class
    By Epo in forum Game Programming
    Replies: 2
    Last Post: 07-10-2005, 02:33 PM
  4. OpenGL Window
    By Morgul in forum Game Programming
    Replies: 1
    Last Post: 05-15-2005, 12:34 PM
  5. OpenGL and Windows
    By sean345 in forum Game Programming
    Replies: 5
    Last Post: 06-24-2002, 10:14 PM