• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 352
  • Last Modified:

Call Menu Function OnUpdate

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
Thomas Stockbruegger
Asked:
Thomas Stockbruegger
  • 2
  • 2
1 Solution
 
AndyAinscowFreelance programmer / ConsultantCommented:
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
 
Thomas StockbrueggerAuthor Commented:
yes... that do I mean....and I think I  found the answer.
m_AufloesungAuswahl=1;
will do the trick
0
 
AndyAinscowFreelance programmer / ConsultantCommented:
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
 
Thomas StockbrueggerAuthor Commented:
okay...thanks...sometimes you only need a hint
0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

Join & Write a Comment

Featured Post

Get your problem seen by more experts

Be seen. Boost your question’s priority for more expert views and faster solutions

  • 2
  • 2
Tackle projects and never again get stuck behind a technical roadblock.
Join Now