Topic: Menus

I was trying to put together a menu using Mathias template but couldn't get it working.


Any help please...


Please see the attached sample project:

Post's attachments

Attachment icon MENUs Test.zip 14.42 kb, 399 downloads since 2016-12-26 

Adam
God... please help me become the person my dog thinks I am.

Re: Menus

Hello Ad1408

Please try this other formula

There are many ways to create personal menus with MVD
This one proposed by Dmitry is the simplest.

See attachment (menus titles and sub titles are in french but they are easy to translate)

JB

Post's attachments

Attachment icon MES MENUS PERSOS.rar 315.89 kb, 433 downloads since 2016-12-26 

Re: Menus

Hi JB,


Thanks a lot for the sample project......


With my sample project, I wanted to use actual menu item names rather than MyItem1, MySubItem1 and so on.
Again, I wanted each menu item performs appropriate onclick action rather than generic ShowMessage.

Adam
God... please help me become the person my dog thinks I am.

Re: Menus

Hello Adam, and happy new year,


I had a look at your project and corrected it.


To find the errors, I commented all the procedures and menu click and then reactivated them one by one.


Problems were :
- a TMenuItem inserted twice
- a few typos in event handler names


I added ShowMessage to menus with no action to test them.


have a good day and, again, a happy new year



Cheers



Math

Post's attachments

Attachment icon MENUs_Test.zip 344.93 kb, 438 downloads since 2017-01-01 

I'm a very good housekeeper !
Each time I get a divorce, I keep the house

Zaza Gabor

Re: Menus

Hi Mathias,


Thanks a lot.............

Adam
God... please help me become the person my dog thinks I am.

Re: Menus

Thanks to you guys (especially Math), I learned how to create new menus, adding menu items to MVD default menus etc.


However, I stuck on hiding MVD default menu / menu item. For instance, I wanted to keep MVD defult menu Options but hide the menu item Report designer under under Options menu?

Adam
God... please help me become the person my dog thinks I am.

Re: Menus

Hello AD1408

To hide the menu item Report designer under under Options menu :

Form1.mniReport.Visible := False;

Good Luck

JB

Re: Menus

http://myvisualdatabase.com/forum/viewtopic.php?id=1440

Dmitry.

Re: Menus

Hi JB,


Thank you very much....


I was trying
Form1.mniReportDesigner.Visible := False;

Adam
God... please help me become the person my dog thinks I am.