R
Rob W
Greetings,
I have a MDI text editor with 5 menus File, Edit, Tools, Windows and Help
I have written code for every time the user hovers on one of the sub menus
Edit, Tools or Windows i.e. the ToolStripMenuItem if MDIChildren.count is
zero then loop around all the ToolStripMenuItem.dropdownlist items and sets
enabled to false.
I then thought it was very inefficient to check this every time the user
when to use a menu option.
I decided it would be best to ENABLE the menu options (Default on load is
menu items are disabled) when the first MDIchild form is created.
Then on the last MDIchild being closed to DISABLE the items.
I then looked at the _MdiChildActivate event which triggers every time a
MdiChild is open, closed or activated.
I can't however use a count or length to determine when the last MdiChild
has been close as the code is triggered before it closes down.
Any ideas how I can determine when the last MDIChild is being closed to
allow me to disable the menuitems ??
Thanks for those who helped me with OOP programming reading properties from
other classes.
Thanks
Rob
I have a MDI text editor with 5 menus File, Edit, Tools, Windows and Help
I have written code for every time the user hovers on one of the sub menus
Edit, Tools or Windows i.e. the ToolStripMenuItem if MDIChildren.count is
zero then loop around all the ToolStripMenuItem.dropdownlist items and sets
enabled to false.
I then thought it was very inefficient to check this every time the user
when to use a menu option.
I decided it would be best to ENABLE the menu options (Default on load is
menu items are disabled) when the first MDIchild form is created.
Then on the last MDIchild being closed to DISABLE the items.
I then looked at the _MdiChildActivate event which triggers every time a
MdiChild is open, closed or activated.
I can't however use a count or length to determine when the last MdiChild
has been close as the code is triggered before it closes down.
Any ideas how I can determine when the last MDIChild is being closed to
allow me to disable the menuitems ??
Thanks for those who helped me with OOP programming reading properties from
other classes.
Thanks
Rob