Solved

Call Menu Function OnUpdate

Posted on 2011-02-22
4
306 Views
Last Modified: 2012-05-11
Hello,
I would like to call a Menu Update Function in CMainFrame from another Function:

My Update Function is:
void CMainFrame::OnUpdate_Aufloesung1280x1024(CCmdUI *pCmdUI)
{
    pCmdUI->SetCheck(m_AufloesungAuswahl==CMainFrame::Auswahl_1);
}
This will be called if I choose this menu.....and the check box will set in this menu.


How can I call this Function from another Function in CMainFrame?
Please let me know.
Thank you.
500 points.
Best regards,
Thomas
0
Comment
Question by:tsp2002
  • 2
  • 2
4 Comments
 
LVL 44

Expert Comment

by:AndyAinscow
ID: 34951734
This function should be called automatically when the menu is displayed - you don't have any need to call it yourself.  Do you mean you need to set the value of m_AufloesungAuswahl from elsewhere but don't know how to?
0
 

Author Comment

by:tsp2002
ID: 34951797
yes... that do I mean....and I think I  found the answer.
m_AufloesungAuswahl=1;
will do the trick
0
 
LVL 44

Accepted Solution

by:
AndyAinscow earned 500 total points
ID: 34951821
Yes, set the value of m_AufloesungAuswahl to be CMainFrame::Auswahl_1 if you want the check to be displayed on the menu point, setting it to another value will remove the check mark
0
 

Author Closing Comment

by:tsp2002
ID: 34951843
okay...thanks...sometimes you only need a hint
0

Featured Post

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

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

The following diagram presents a diamond class hierarchy: As depicted, diamond inheritance denotes when two classes (e.g., CDerived1 and CDerived2), separately extending a common base class (e.g., CBase), are sub classed simultaneously by a fourt…
In Easy String Encryption Using CryptoAPI in C++ (http://www.experts-exchange.com/viewArticle.jsp?aid=1193) I described how to encrypt text and recommended that the encrypted text be stored as a series of hexadecimal digits -- because cyphertext may…
This Micro Tutorial will teach you how to censor certain areas of your screen. The example in this video will show a little boy's face being blurred. This will be demonstrated using Adobe Premiere Pro CS6.
This Micro Tutorial demonstrates using Microsoft Excel pivot tables, how to reverse engineer competitors' marketing strategies through backlinks.

912 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

Need Help in Real-Time?

Connect with top rated Experts

16 Experts available now in Live!

Get 1:1 Help Now