Hi!
I have a toolStrip with several buttons. Each button opens a new form.
With some forms I disable just its button, but with others I disable three buttons.
After I close any form, I re-enable the button.
As it isn't always the same amount of buttons, I'd like to do a routine to re-enable the buttons after I close any form.
I've tried with:
andCode:For Each Ctrl As Control In Me.Controls Ctrl.GetType() If (Ctrl Is ToolStripButton) Then Ctrl.enabled = true End If Next
But any of them work...Code:For Each StripButton As ToolStripButton In MDIParent1.Controls If Controls.Equals(StripButton) Then StripButton.Enabled = True End If Next
could anyone please, give me a hand with this?
Thanks in advance.




Reply With Quote