?
Solved

Extracting Menu Array from an Application

Posted on 2003-03-18
6
Medium Priority
?
228 Views
Last Modified: 2010-04-01
My goal is to produce training that includes simulated menus from a variety of applications (Word, Excel, Dreamweaver, etc.). Part of the procedure for creating the training will be to come up with a list of sub- and sub-sub menu under each of the applications top-level menus. For example, for the menus in IE, I need a text file with info something like this:

File
 New
  Window
  <divider>
  Message
  Post
 Open
 Edit
...

I don't want to do this by hand, but want an app that will get the list of menu items automagically. (Years ago I came across an app that would suck the menus out of an application and throw them into an array in a text file, but can't find anything like it now.)
 
My question: Do you know of an application (or some source code) that can give me a menu-item list if I point it at a application?

Thanks. Jim

 
0
Comment
Question by:jrubino
[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
6 Comments
 
LVL 1

Expert Comment

by:keitha1
ID: 8164595
In general, an automatic resource extractor wouldn't be reliable because a great deal of software will build the menu's on the fly inside the program.

But if you still want, here is a link to a freeware resource extractor. The output is a little goofy and is dumped under the directory where you install this program.


http://demosten.com/resextr/
0
 
LVL 49

Expert Comment

by:DanRollins
ID: 8165273
Have you tried the GetMenu(), GetMenuItemCount(), and GetMenuItemInfo() APIs?  There is some chance that GetMenuItemInfo() will fail when trying to access a menu in an external program.  In that case, there are a couple of workarounds.

Anyway, please notice that all high-powered programs like Word and Excel allow for user customization and even the latest wrinkle in which seldom-used menu items are hidden.  Thus, you have set youself a difficult task.  Plrobaly easier to just write them down.

-- Dan
0
 

Author Comment

by:jrubino
ID: 8166817
Nice suggestion, but the resource extractor didn't give me any menus.

Yes, Dan, GetMenu(), GetMenuItemCount(), and GetMenuItemInfo are my plan B. I just didn't want to re-invent something already available. Writing the menus by hand is plan C, but a tool could save us hundreds of hours/year.

Thanks.

Jim
0
VIDEO: THE CONCERTO CLOUD FOR HEALTHCARE

Modern healthcare requires a modern cloud. View this brief video to understand how the Concerto Cloud for Healthcare can help your organization.

 
LVL 1

Accepted Solution

by:
MattRobb earned 2000 total points
ID: 8169364
0
 

Author Comment

by:jrubino
ID: 8175802
Thanks, Matt. This will do a lot of work for me.

For some reason, though, it does not work with Microsoft products. Any ideas?

Jim
0
 
LVL 1

Expert Comment

by:MattRobb
ID: 8178873
That’s because Microsoft doesn’t use standard menus in this products. Actually some of them don’t have a menu at all. Instead they have a toolbar, for instance, with buttons displaying only text.
0

Featured Post

VIDEO: THE CONCERTO CLOUD FOR HEALTHCARE

Modern healthcare requires a modern cloud. View this brief video to understand how the Concerto Cloud for Healthcare can help your organization.

Question has a verified solution.

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

Often, when implementing a feature, you won't know how certain events should be handled at the point where they occur and you'd rather defer to the user of your function or class. For example, a XML parser will extract a tag from the source code, wh…
This article will show you some of the more useful Standard Template Library (STL) algorithms through the use of working examples.  You will learn about how these algorithms fit into the STL architecture, how they work with STL containers, and why t…
The goal of the video will be to teach the user the difference and consequence of passing data by value vs passing data by reference in C++. An example of passing data by value as well as an example of passing data by reference will be be given. Bot…
The viewer will be introduced to the technique of using vectors in C++. The video will cover how to define a vector, store values in the vector and retrieve data from the values stored in the vector.
Suggested Courses

770 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