Probs accessing menus

Hi,

I have a mdiform named mdiMain and a menu named menMain....I have a modal form from which in its button click event, i want to disable some menu items....How should it be done? Please help

Thanks,

Prem

[212 byte] By [codefund.com] at [2007-12-16]
# 1
1) On mdiMain, you should make your menuItems public(they are private by default)
2) when showing your modal for you should use the show method that takes an owner. For example modalForm.Show(this);
3) In you button click on the modal form you will need code that look like the following for each menuItem you wish to disable:
((mdiMain)this.Owner).menuItem2.Enabled =false;
codefund.com at 2007-9-8 > top of Msdn Tech,Windows Forms,Windows Forms General...