Click to See Complete Forum and Search --> : Mdi Forms?


nolc
July 16th, 2002, 03:40 PM
DOES ANYONE KNOW OF A GOOD MDI FORMS EXAMPLE IN .NET? OR CAN YOU SEND ME SOME TIPS? I'VE NEVER USED MDI FORMS IN VB6 OR PREVIOUS VERSIONS...SO I'M NEW WITH THIS.

THANKS

letford
July 23rd, 2002, 04:48 PM
Hi,
You have to set the form that you select as the MDI and change its IsMDIContatiner property to true.

This is an example of calling a form: Pretty new to it myself in .Net so just stumbling along.


If m_frmUsers Is Nothing Then
m_frmUsers = New frmUsers()
End If

m_frmUsers.MdiParent = Me
m_frmUsers.Show()
m_frmUsers.BringToFront()

I was also given good advice of someone to dim my form withevents and add this code to the closing event.

Private Sub m_frmUsers_Closing(ByVal sender As Object, ByVal e As System.ComponentModel.CancelEventArgs) Handles m_frmUsers.Closing
m_frmUsers = Nothing
End Sub

Hope this helps.

nolc
July 23rd, 2002, 05:55 PM
definetly thanks..