Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Delphi IDE custom menu items, how to Add them?

I am working on a project using Delphi 7 and Delphi 2006, i am developing a component that will get certain system information. Now the requirement is that after the component is installed on the system, there should be a menu item on the IDE , like this

enter image description here

and for delphi 7 like this enter image description here

i have searched on the net about adding a menu item but i have not got anything to add an item to the IDE like the one EurekaLog has. can any body tell me how to add the item like EurekaLog or mysql ? is it some where in the registry?

like image 975
PresleyDias Avatar asked Apr 23 '12 07:04

PresleyDias


1 Answers

To add a menu to the Delphi IDE you must use the Delphi Open Tools API. from here you can access the Main menu of the delphi IDE using a code like this.

LMainMenu:=(BorlandIDEServices as INTAServices).MainMenu;

or

LMainMenu:=(BorlandIDEServices as INTAServices).GetMainMenu;

And then add the menu items which you want.

Check these links for additional samples

  • Open Tools API Chapter 15: IDE Main Menus
  • Introduction to the Delphi Open Tools API
  • How can I add a menu item to the IDE’s main menu?
like image 103
RRUZ Avatar answered Sep 21 '22 01:09

RRUZ