Go Premium for a chance to win a PS4. Enter to Win

x
?
Solved

MDI form stays ontop but parent is still enabled

Posted on 2004-09-25
2
Medium Priority
?
194 Views
Last Modified: 2010-05-02
I have a MDI form with a child MDI form being displayed by a SDI application.  I have the MDI form ontop of all other forms working fine, but the SDI is still active [enabled] and I don't want the user to be able to close it without closing the MDI form first.

I tried disabling the SDI form before showing the MDI form with the vbModal parameter, then enabling it after the .Show call, but vbModal doesn't seem to work with MDI forms - I've read that too.

How can I get the SDI form to become disabled when the MDI form is active, then get enabled after the user closes the MDI form?

Thanks.
0
Comment
Question by:halfondj
2 Comments
 
LVL 32

Accepted Solution

by:
Erick37 earned 1000 total points
ID: 12151554
Have you tried this...

In the MDI code:

Sub MDIForm_Load
    'Disable the SDI here
    frmSDIForm.enabled = False
End Sub

Sub MDIForm_UnLoad
    'Enable the SDI here
    frmSDIForm.enabled = True
End Sub
0
 

Author Comment

by:halfondj
ID: 12151632
After confirming what you posted re:what I knew, I realized my problem.

Thanks.  All is now working!
0

Featured Post

VIDEO: THE CONCERTO CLOUD FOR HEALTHCARE

Modern healthcare requires a modern cloud. View this brief video to understand how the Concerto Cloud for Healthcare can help your organization.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

When designing a form there are several BorderStyles to choose from, all of which can be classified as either 'Fixed' or 'Sizable' and I'd guess that 'Fixed Single' or one of the other fixed types is the most popular choice. I assume it's the most p…
This article describes how to use a set of graphical playing cards to create a Draw Poker game in Excel or VB6.
As developers, we are not limited to the functions provided by the VBA language. In addition, we can call the functions that are part of the Windows operating system. These functions are part of the Windows API (Application Programming Interface). U…
Get people started with the utilization of class modules. Class modules can be a powerful tool in Microsoft Access. They allow you to create self-contained objects that encapsulate functionality. They can easily hide the complexity of a process from…
Suggested Courses

972 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question