Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

MDI Child form problems

Status
Not open for further replies.

dsoutherland

Programmer
Feb 26, 2004
15
0
0
I have a simple VB6 app that I was asked to make some mods to. The app merely displays data out of a database through a series of prompted steps on several MDI Child forms. A final form is displayed with the requested information for the user. The only active control on the final form is a button that closes the form to return to the previous form. Here's the problem: I was asked to change the way data is displayed on that final form from a set of text boxes to a flex grid, since data requirements have changed in the database and the amount of data may exceed the previous limited number of text boxes. I removed the text boxes and all the code supporting them and added a flex grid and the code to display the same information in rows in the flex grid. Now when I go through the steps to get to the final form, the form displays but is not active. The close button is not active, the minimize-maximize-close buttons at the top of the form are not active and when I inquired in the immediate window for form.enabled, the reply was false. I added a "previous" button in the taskbar of the parent form that closes the child forms in sequence and when all the child forms are closed, a second copy of the problem form is shown in minimized size. What gives??? Any ideas???
 
Check the properties window of the final child form to see if .Enabled is set to False. Also, you could put "Me.Enabled = True" in the Form_Paint or Form_Activate event.



I used to rock and roll every night and party every day. Then it was every other day. Now I'm lucky if I can find 30 minutes a week in which to get funky. - Homer Simpson
 
Works now. Thanks!! Why should this be necesary - Me.Enabled = True ???
 
Well, the form is being disabled somewhere in the code, or has its Enabled property set to False in the Properties window. Did you check that? Setting Me.Enabled = True just enables the form, the way you want it to be.

I used to rock and roll every night and party every day. Then it was every other day. Now I'm lucky if I can find 30 minutes a week in which to get funky. - Homer Simpson
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top