Let me explain in detail
I have a Form called frmMainMenu this has a menu item called Employee information. when i click this it will disable the menu item employee information and load the frmEmployee form
When i have finished with the frmEmployee form i want to enable the menu item Employee information when the frmEmployee form closes.
so the code behind the frmMainMenu, Menu item 'Employee Information' is:
and the code behind the frmEmployee is:Code:Private Sub MenuItemEmployeeInfo_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MenuItemEmployeeInfo.Click Dim frmEmployeeOpen As New frmEmployee frmEmployeeOpen.Owner = Me frmEmployeeOpen.MdiParent = Me MenuItemEmployeeInfo.Enabled = False frmEmployeeOpen.Show() End Sub
hope this helpsCode:Private Sub frmEmployee_Closed(ByVal sender As Object, ByVal e As System.EventArgs) Handles MyBase.Closed Dim frmMainMenuItem As frmMainMenu frmMainMenuItem.MenuItemEmployeeInfo.Enabled = True End Sub
Thanks




Reply With Quote