Solved

Menu???

Posted on 1998-10-21
1
192 Views
Last Modified: 2013-11-20
Hi,

I want to ask how to enable/disable the item at the menu.
eg. I want to disable one item after opening a document.
    Then enable this item after closing this document.
How can I do this?

Thanks.
0
Comment
Question by:cplau
1 Comment
 
LVL 1

Accepted Solution

by:
Bridge earned 40 total points
Comment Utility
put this in you document cpp;

ON_UPDATE_COMMAND_UI(ID_???, OnUpdate???)

void CDocumentOverride::OnUpdate???(CCmdUI* pCmdUI)
{
   pCmdUI->Enable( FALSE );
}

put this in you document h;

afx_msg void OnUpdate???(CCmdUI* pCmdUI);
0

Featured Post

How your wiki can always stay up-to-date

Quip doubles as a “living” wiki and a project management tool that evolves with your organization. As you finish projects in Quip, the work remains, easily accessible to all team members, new and old.
- Increase transparency
- Onboard new hires faster
- Access from mobile/offline

Join & Write a Comment

Suggested Solutions

Title # Comments Views Activity
cat dog challenge 18 122
iSeries FTP Exit Program 8 113
Shell script to login to remote m/c and execute commands 10 72
sum67 challenge 35 88
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…
Introduction: Database storage, where is the exe actually on the disc? Playing a game selected randomly (how to generate random numbers).  Error trapping with try..catch to help the code run even if something goes wrong. Continuing from the seve…
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.
You have products, that come in variants and want to set different prices for them? Watch this micro tutorial that describes how to configure prices for Magento super attributes. Assigning simple products to configurable: We assigned simple products…

771 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

11 Experts available now in Live!

Get 1:1 Help Now