Custom MenuItems

  • Thread starter =?ISO-8859-1?Q?Carlos_Guzm=E1n_=C1lvarez?=
  • Start date
?

=?ISO-8859-1?Q?Carlos_Guzm=E1n_=C1lvarez?=

Hello:

There are any way to make a MainMenu that creates the menu items
based a custom MenuItem implementation ??


Thanks in advance !!
 
M

Mohamoss

Hi Carlos
Although it it not clear what you want . but you can create you own custom
menu control. You will create a windows control project. just create a
custom control menu that inherit the windows menu control then do your
desired modifications on that .
Mohamed Mahfouz
MEA Developer Support Center
ITworx on behalf of Microsoft EMEA GTSC
 
G

Guest

As Mohamoss suggested, inherit your MainMenu from System's MainMenu.
Then add a method to it that creates menu items and subitems with the
strings passed to that method.
Define some properties like display value, form_to_open, a Dataset or
something that can store some data. Then retrieve the menu structure from an
XML file or from a database into the Dataset and foreach record, call the
method declared above.
Create a dll with this control.
Drop your control on a form and on the load method of the form, call the
method on your MainMenu control that retreives menu data and creates the menu.

I guess this is something you want to do.

Hope it helps.
 
G

Guest

Hello:

Thanks for the answer.
As Mohamoss suggested, inherit your MainMenu from System's MainMenu.
Then add a method to it that creates menu items and subitems with the
strings passed to that method.

Well the idea was to use a custom MainMenu and a custom MenuITem
implementation.

What i want to know is if at design time i can add my custom MenuItem
to the MainMenu (what the .net MAinMEnu and MenuITem do but using my own
custom implementations thay overrides from the .net ones, not sure
if it's clear now)
 

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