Expiring Today—Celebrate National IT Professionals Day with 3 months of free Premium Membership. Use Code ITDAY17

x
?
Solved

MDI form stays ontop but parent is still enabled

Posted on 2004-09-25
2
Medium Priority
?
188 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
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
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

On Demand Webinar: Networking for the Cloud Era

Did you know SD-WANs can improve network connectivity? Check out this webinar to learn how an SD-WAN simplified, one-click tool can help you migrate and manage data in the cloud.

Question has a verified solution.

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

Introduction While answering a recent question (http://www.experts-exchange.com/Q_27402310.html) in the VB classic zone, I wrote some VB code in the (Office) VBA environment, rather than fire up my older PC.  I didn't post completely correct code o…
This article describes some techniques which will make your VBA or Visual Basic Classic code easier to understand and maintain, whether by you, your replacement, or another Experts-Exchange expert.
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…
Show developers how to use a criteria form to limit the data that appears on an Access report. It is a common requirement that users can specify the criteria for a report at runtime. The easiest way to accomplish this is using a criteria form that a…
Suggested Courses

718 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