Simple Windows Question

This is a discussion on Simple Windows Question within the Windows Programming forums, part of the Platform Specific Boards category; I have a program with 2 windows, one main and an auxilliary one. When I close the auxilliary one, I ...

  1. #1
    Budding Synth Programmer samGwilliam's Avatar
    Join Date
    Feb 2002
    Location
    Trefforest
    Posts
    368

    Simple Windows Question

    I have a program with 2 windows, one main and an auxilliary one. When I close the auxilliary one, I can't get it to show again (with the ShowWindow () function).

    I'm guessing it's being destroyed - not simply hidden - even though I'm issuing a hide command from the window's event handler (under WM_CLOSE). I'm destroying both from the main window's WM_CLOSE.

    Can anyone help? I'm guessing it's going to be something simple...
    MSVC++ 6.0

  2. #2
    Registered User Codeplug's Avatar
    Join Date
    Mar 2003
    Posts
    4,660
    Make sure that DefWindowProc() isn't handling the message and that you return 0 from your message handler after hiding the window.

    gg

  3. #3
    Budding Synth Programmer samGwilliam's Avatar
    Join Date
    Feb 2002
    Location
    Trefforest
    Posts
    368
    That fixed it, thanks!
    MSVC++ 6.0

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. MFC simple question
    By dole.doug in forum Windows Programming
    Replies: 5
    Last Post: 09-26-2008, 06:11 AM
  2. A question about windows programming
    By Hussain Hani in forum Windows Programming
    Replies: 16
    Last Post: 05-23-2007, 07:38 AM
  3. Replies: 5
    Last Post: 08-16-2006, 02:05 PM
  4. Simple fp_in question.
    By BluePudding in forum C++ Programming
    Replies: 5
    Last Post: 08-09-2006, 08:18 AM
  5. General question about Windows resources
    By Boomba in forum Windows Programming
    Replies: 2
    Last Post: 07-19-2004, 09:36 PM

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21