Create a ContextMenu

F

Fritz Switzer

I have a two part question.

I would like to provide a run-time feature that would duplicate the
design-time capability to create a Context Menu. This would be where the
user could create their own ContextMenus. I would like to save this Menu
structure as either XML or a text file using C#.

The iterface for creating menus (either Main Menu/ or Context Menu) is very
simple, but trying to understand how to add different levels (either
drop-downs or fly-outs) is confusing especially as the nesting goes deeper
down.

Question #1. Is there a way to extend the Menu creation capabilites in the
IDE using C# and persist the structure and labels to programmatically
save/load different context menus from and end-users pespective. (For
example the user wants to create a number of context menus, and select the
different context menus for a control from a listbox)

Question #2. How else could one create this functionality in C#?

TIA,

Fritz
 
T

thomas woelfer

Fritz,
Question #1. Is there a way to extend the Menu creation capabilites in the IDE using C# and persist the structure and labels to
programmatically save/load different context menus from and end-users pespective. (For

nope. you need to build that functionality yourself.
Question #2. How else could one create this functionality in C#?

well basically, all you need is some kind of file where you store the content
of the menus. xml certainly maps quite good for this purpose. during
runtime, you simple read that file and create the menus....

hm... i'm not sure this is an answer - maybe i didn't understand the
question :)

WM_HOPETHISHELPS
thomas woelfer
http://www.die.de/blog
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Similar Threads


Top