Click here to Skip to main content
15,905,612 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
GeneralWhy Visual C++ generates other function name, but I use extern "C" Pin
Gasanov Tagir15-Nov-04 4:41
Gasanov Tagir15-Nov-04 4:41 
GeneralRe: Why Visual C++ generates other function name, but I use extern "C" Pin
David Crow15-Nov-04 4:59
David Crow15-Nov-04 4:59 
GeneralRe: Why Visual C++ generates other function name, but I use extern "C" Pin
Blake Miller15-Nov-04 10:25
Blake Miller15-Nov-04 10:25 
GeneralRe: Why Visual C++ generates other function name, but I use extern "C" Pin
Gasanov Tagir15-Nov-04 22:49
Gasanov Tagir15-Nov-04 22:49 
QuestionDynamic menus and messages? Pin
One Stone15-Nov-04 4:40
One Stone15-Nov-04 4:40 
AnswerRe: Dynamic menus and messages? Pin
Antony M Kancidrowski15-Nov-04 6:43
Antony M Kancidrowski15-Nov-04 6:43 
GeneralWaiting On Mutes's Pin
sweep12315-Nov-04 4:30
sweep12315-Nov-04 4:30 
GeneralRe: Waiting On Mutes's Pin
Antony M Kancidrowski15-Nov-04 6:12
Antony M Kancidrowski15-Nov-04 6:12 
QuestionHow to get full path of exe file? Pin
pubududilena15-Nov-04 2:00
pubududilena15-Nov-04 2:00 
AnswerRe: How to get full path of exe file? Pin
dabs15-Nov-04 2:09
dabs15-Nov-04 2:09 
GeneralRe: How to get full path of exe file? Pin
pubududilena15-Nov-04 6:15
pubududilena15-Nov-04 6:15 
GeneralRe: How to get full path of exe file? Pin
Maximilien15-Nov-04 6:24
Maximilien15-Nov-04 6:24 
GeneralRe: How to get full path of exe file? Pin
dabs15-Nov-04 6:28
dabs15-Nov-04 6:28 
GeneralRe: How to get full path of exe file? Pin
pubududilena15-Nov-04 6:49
pubududilena15-Nov-04 6:49 
GeneralRe: How to get full path of exe file? Pin
Maximilien15-Nov-04 7:31
Maximilien15-Nov-04 7:31 
GeneralScroll bar Pin
shijuck15-Nov-04 2:00
shijuck15-Nov-04 2:00 
GeneralScrool Bar Painting issue Pin
anuragvelekkattu15-Nov-04 1:53
anuragvelekkattu15-Nov-04 1:53 
GeneralON_UPDATE_COMMAND_UI impossible to change the state of items Pin
madretierra15-Nov-04 1:06
madretierra15-Nov-04 1:06 
Hello,

is there anybody to explain me how to disable an item from a menu ?
One of my items are for exemple ID__STOP :

in my .h file:
afx_msg void OnChoixMenuStop();
afx_msg void OnUpdateMenuStop(CCmdUI *pCmdUI);

and in my .cpp file :

BEGIN_MESSAGE_MAP(CAppDlg, CDialog)

ON_COMMAND(ID__STOP, OnChoixMenuStop)
ON_UPDATE_COMMAND_UI(ID__STOP, OnUpdateMenuStop)

END_MESSAGE_MAP()

void CAppDlg::OnContextMenu(CWnd* pWnd, CPoint point)
{

CMenu menu;

menu.LoadMenu(IDR_POPUPMENU);
menu.GetSubMenu(0)->TrackPopupMenu(TPM_LEFTALIGN | TPM_RIGHTBUTTON,point.x, point.y, this);

}


void CAppDlg::OnUpdateMenuStop(CCmdUI *pCmdUI)
{

pCmdUI->Enable(FALSE);

}
I would like to get it grayed or disabled but i can't...
Please if you can help me it would be great !

There is no way to happiness, happiness is the way !
GeneralRe: ON_UPDATE_COMMAND_UI impossible to change the state of items Pin
Archigal15-Nov-04 3:05
Archigal15-Nov-04 3:05 
GeneralRe: ON_UPDATE_COMMAND_UI impossible to change the state of items Pin
madretierra15-Nov-04 3:17
madretierra15-Nov-04 3:17 
GeneralImage Colour Management Pin
apollo-house15-Nov-04 0:48
apollo-house15-Nov-04 0:48 
GeneralEnumDisplaySettings gives wrong values Pin
Ray Adams14-Nov-04 23:48
Ray Adams14-Nov-04 23:48 
GeneralRe: EnumDisplaySettings gives wrong values Pin
Antony M Kancidrowski15-Nov-04 0:33
Antony M Kancidrowski15-Nov-04 0:33 
GeneralRe: EnumDisplaySettings gives wrong values Pin
Ray Adams15-Nov-04 0:46
Ray Adams15-Nov-04 0:46 
GeneralRe: EnumDisplaySettings gives wrong values Pin
Antony M Kancidrowski15-Nov-04 3:02
Antony M Kancidrowski15-Nov-04 3:02 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.