How to show menu's of both MDI and Child form

nitin_bt
01-16-2001, 04:11 AM
Hello everybody

I have one MDI form and one child form. Both form have menu

objects .

But since i want the menu should be pop up menu for child

form i made it visible false. so when user right clicks the child

form then the menu for child will get display.

But the problem is that at same time it not shows the menu

the MDI for. I have to show both the menu's at a time .

What should i do ?

Nitin

JAJ
02-11-2001, 08:18 AM
I think I had a similar problem. The way I got round it was to use the Windows api to create a popup menu. If you remove the menu information from the form, the mdi form menu should always be displayed, and you'll have your popup menu as well. It also means that you can dynamically edit the popup menu at run-time. Attached is the class I use to do it - I can't claim credit for writing it - I found it somewhere, but I've forgotten who... /images/icons/laugh.gif Anyway, just create an instance of the class, and call the function Popup passing a string array containing the menu items. The function returns an index code to the menuitem selected, or 0 if none was selected.

EZ Archive Ads Plugin for vBulletin Copyright 2006 Computer Help Forum