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
Solved

Change Menu Pulldown string?

Posted on 2001-07-25
1
284 Views
Last Modified: 2013-11-20
Hi.
I want to change the strings in a menu programatically.
I have a menu resource that gets loaded by my CFrameWnd.
I figured out how to alter the items in the menu:

* override ::OnCreate() in CFrameWnd
* GetMenu()->ModifyMenu(id,MF_BYCOMMAND|MF_STRING,id,"newstring");

However I do not know how to change the string in the pulldown itself.
(ie: File, Edit, Help, etc)

Does anybody know how to do this?

Thanks.
0
Comment
Question by:bwilhelm
1 Comment
 
LVL 49

Accepted Solution

by:
DanRollins earned 100 total points
ID: 6320361
I think you wnat to modify the text in the menubar.  If so, you need to use positions rather that commands.  For instance, this changes the title of the seconf menu item (usually "&Edit") to "&Whaz UP!"

  GetMenu()->ModifyMenu( 1, MF_BYPOSITION|MF_STRING, 2, "&Whaz UP!" );

-- Dan
0

Featured Post

Free Tool: Site Down Detector

Helpful to verify reports of your own downtime, or to double check a downed website you are trying to access.

One of a set of tools we are providing to everyone 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

Suggested Solutions

Title # Comments Views Activity
ODBC Connection Logging, ADO.NET 6 69
viewing source code from eclipse 13 110
Line meaning 9 87
Excel file not created as expected 7 79
In this article, I'll describe -- and show pictures of -- some of the significant additions that have been made available to programmers in the MFC Feature Pack for Visual C++ 2008.  These same feature are in the MFC libraries that come with Visual …
Introduction: Displaying information on the statusbar.   Continuing from the third article about sudoku.   Open the project in visual studio. Status bar – let’s display the timestamp there.  We need to get the timestamp from the document s…
This video will show you how to get GIT to work in Eclipse.   It will walk you through how to install the EGit plugin in eclipse and how to checkout an existing repository.

860 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