Hi I was wondering if anyone can help me.

I have a program that has an MDIChild form which contains a button that opens up a second MDIChild form. This second form has a listbox checkbox on it that allows the user to select from. Once they have finished selecting, I need the second MDIChild form to close and return focus to the first MDIChild form.

The problem I am getting is when I close the second MDIChild form and try to return to the first one, instead of updating the first form that is already loaded it is creating a new instance of the first MDIChild form so I am getting 2!!

Does anyone know anything about this?

Recommended Answers

All 2 Replies

Yes, you have code something like this...

Dim F As New Form1
F.Show

somewhere in your code. Find it, change it to Form1.Show. Should fix it.

Good Luck

Thank you very much vb5prgrmr! perfect answer, sorted it straight away :)

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.