all groups > dotnet general > june 2004 >
You're in the

dotnet general

group:

Generic Context Menu



Generic Context Menu jasenlaw NO[at]SPAM hotmail.com
6/30/2004 6:22:32 PM
dotnet general: Hi,

May I know how to make a generic context menu (which may contains
save, new or other funtions) to be inherited by different winform?

Thanks in advance.

Re: Generic Context Menu magnusbl NO[at]SPAM simnet.is
7/1/2004 3:22:10 AM
One way to do this would be to have a base form (which derives from
System.Windows.Forms.Form), then all your forms derive from that form.
In the base class you would have a function that returns your menu
items.
Event handler for those, could either be in the base form (if they are
generic) or implemented (overwritten) in each form.

brg,
Magnús

[quoted text, click to view]
AddThis Social Bookmark Button