Hi,
My parent MDI form (MDIForm1) has opens various child forms on their respective menu click events.
I want to know that :
1) How will I check if a particular child form is already open?
2) On closing the MDIForm1 if any of the child forms are open then it must popup a message box and wait until the user manually closes each and every child form before closing the parent MDIForm1. How should i do this?
RahulV
16
Junior Poster in Training
Recommended Answers
Jump to Posttry to use some flag setting for loading and unloading of child forms and check the same during unload of the MDI form.
Jump to PostIn the mdi parent (main form) when you want to get the caption of the foreground/active window, you can use
msgbox me.activeform.caption
to get the caption of the active child MDI form.To find out if the window is loaded and visible you can use this (add it …
Jump to PostFindWindow API Call. You might be able to use something like
retval = appactivate("Calculator")
, and then check the return value of retval for success or failure, but I'm not sure if appactivate returns a value... I know findwindows does.
All 9 Replies
debasisdas
580
Posting Genius
Featured Poster
RahulV
16
Junior Poster in Training
RahulV
16
Junior Poster in Training
Comatose
290
Taboo Programmer
Team Colleague
RahulV
16
Junior Poster in Training
Comatose
290
Taboo Programmer
Team Colleague
RahulV
16
Junior Poster in Training
QVeen72
104
Posting Shark
jireh
3
Posting Whiz
Be a part of the DaniWeb community
We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.