|
-
Sep 11th, 2000, 10:46 AM
#1
Thread Starter
Hyperactive Member
I have an MFC MDI app and I want to implement a 'Window' menu that shows the first nine windows I have open. I can't use the built int 'Window' menu because my app, for reasons of display speed, doesn't close documents, it just hides them (i.e. in the auto version when you 'shut' a window, it stays in the window list).
Anyway, I've put in code that displays the window names based on whether they're visible or not. I (foolishly?) gave them all the same resource ID when appending to the menu, thinking it'd be easy to extract the text and therefore activate the right window. However, I can't seem to extract the text of the selected menu item from my 'OnWindow()' handler. I could give all my menu items separate resource IDs and write separate handlers for each, but as they'd all do the same thing, that seems dumb.
Can any one help me out? How can I extract the text from a menu item when I don't know its position in the menu?
      
Dan
Outside of a dog, a book is a man's best friend.
Inside of a dog, it's too dark to read.
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|