I'm using this code in my parent form to check if child forms are open, if they are, then I make them the active form. I also open child forms from other child forms. How do I check to see if a form is already open if I'm opening it from another child form?
thanks
Code:Dim blnFound As Boolean = False Dim frmChild As Form For Each frmChild In Me.MdiChildren If TypeOf frmChild Is frmAccountMgmt Then frmChild.Focus() blnFound = True Exit For End If Next 'If form not already loaded then load form If blnFound = False Then Dim frmaccountmgmt1 As New frmAccountMgmt() frmaccountmgmt1.MdiParent = Me frmaccountmgmt1.Show() End If Exit Sub


Reply With Quote