Solved

Loading and merging a menu from a form

Posted on 1997-09-02
3
171 Views
Last Modified: 2010-04-04
I am trying to create a customizable toolbar for my project which uses an MDI form and children. To be able to customize the toolbar I would like to list the items available in the menus and have the user select one. I would also like the user to be able to edit the toolbar without having opened a child window. To do this I need to load the contents of a child window menu and merge it with the current menu and use the results. Creating a new child window and setting visible to false isn't allowed for MDI children. Any suggestions?
0
Comment
Question by:khenr29j
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
3 Comments
 

Expert Comment

by:boabyte
ID: 1343482
Do you want the toolbar a floating one (aka PaintShop Pro style)
or a fixed one like Word etc?
0
 

Author Comment

by:khenr29j
ID: 1343483
I am using the TToolbar component of Delphi 3.0, but it's not really important to the question. I would like to examine the contents of the menus on the MDI child. For example, I keep the Edit menu item on the child so that it's only available when a child window is open. But this also means that I don't know what's on that menu until I actually create a child window.
0
 
LVL 3

Accepted Solution

by:
d4jaj1 earned 150 total points
ID: 1343484
It sounds like you understand how to merge the two forms windows together, but your having a problem merging the two because you dont have access to one.  You can have access to teh child window by creating it, but not showiing it.  To hide a MDI child, use the API call;

showwindow(THE_NAME_OF_YOUR_FORM.handle,SW_Hide);

Now you access to your childs components and you can merge the menus like you would for any visible form.  Any questions, please ask.

PS: - To show a hidden MDI Child window use;

showwindow(THE_NAME_OF_YOUR_FORM.handle,SW_SHOWMAXIMIZED);  // or SW_SHOWNORMAL
0

Featured Post

Free Tool: Path Explorer

An intuitive utility to help find the CSS path to UI elements on a webpage. These paths are used frequently in a variety of front-end development and QA automation tasks.

One of a set of tools we're offering as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

This article explains how to create forms/units independent of other forms/units object names in a delphi project. Have you ever created a form for user input in a Delphi project and then had the need to have that same form in a other Delphi proj…
Have you ever had your Delphi form/application just hanging while waiting for data to load? This is the article to read if you want to learn some things about adding threads for data loading in the background. First, I'll setup a general applica…
In this brief tutorial Pawel from AdRem Software explains how you can quickly find out which services are running on your network, or what are the IP addresses of servers responsible for each service. Software used is freeware NetCrunch Tools (https…
This is my first video review of Microsoft Bookings, I will be doing a part two with a bit more information, but wanted to get this out to you folks.

696 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question