Question about MDI child windows?

This is a discussion on Question about MDI child windows? within the Windows Programming forums, part of the Platform Specific Boards category; Is there a way to get all the child windows of an MDI window, I am trying to make a ...

  1. #1
    Unregistered
    Guest

    Question about MDI child windows?

    Is there a way to get all the child windows of an MDI window, I am trying to make a command to close them all at once but I'm not having any luck.

    Any help appreciated.

  2. #2
    Unregistered
    Guest
    Non MFC, forgot to add that.

  3. #3
    train spotter
    Join Date
    Aug 2001
    Location
    near a computer
    Posts
    3,859
    Try

    FindParent() to get the HWND of the parent window and then sent it a DestroyWindow() . This will close all its children as well.
    "Man alone suffers so excruciatingly in the world that he was compelled to invent laughter."
    Friedrich Nietzsche

    "I spent a lot of my money on booze, birds and fast cars......the rest I squandered."
    George Best

    "If you are going through hell....keep going."
    Winston Churchill

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. Replies: 3
    Last Post: 10-15-2008, 09:24 AM
  2. Simple Windows Question
    By samGwilliam in forum Windows Programming
    Replies: 2
    Last Post: 09-16-2008, 01:50 PM
  3. process programming
    By St0rM-MaN in forum Linux Programming
    Replies: 2
    Last Post: 09-15-2007, 07:53 AM
  4. Tabbed Windows with MDI?
    By willc0de4food in forum Windows Programming
    Replies: 25
    Last Post: 05-19-2005, 10:58 PM
  5. Windows upgrade question
    By 7smurfs in forum Tech Board
    Replies: 11
    Last Post: 10-20-2004, 01:51 PM

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