Click here to Skip to main content
15,921,793 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
AnswerRe: Question Pin
prasad_som13-Dec-06 19:42
prasad_som13-Dec-06 19:42 
GeneralRe: Question Pin
Laxman Auti13-Dec-06 19:58
Laxman Auti13-Dec-06 19:58 
QuestionTextOut & True Type Fonts Pin
PsychicSmurf13-Dec-06 0:02
PsychicSmurf13-Dec-06 0:02 
QuestionCalling an function in a DLL Pin
JJeffrey12-Dec-06 23:59
JJeffrey12-Dec-06 23:59 
QuestionRe: Calling an function in a DLL Pin
prasad_som13-Dec-06 0:14
prasad_som13-Dec-06 0:14 
AnswerRe: Calling an function in a DLL Pin
JJeffrey13-Dec-06 14:21
JJeffrey13-Dec-06 14:21 
AnswerRe: Calling an function in a DLL Pin
ShilpiP13-Dec-06 0:52
ShilpiP13-Dec-06 0:52 
QuestionSetting a menu to OWNERDRAW Pin
manustone12-Dec-06 23:24
manustone12-Dec-06 23:24 
Hi All
I've got a menu to attach to my class derived from CFrameWindow.
I would like to set my menu to OWNERDRAW so that I can draw it and customize the layout.

In the constructor of my window class I put the following but GetMenuItemInfo doesn't work.
It never enters the if block so that I can set the MFT_OWNEDRAW style.
Retrieving the error code I've got 87 ERROR_INVALID_PARAMETER

Can you help me with that issue?
Regards
manustone

<br />
CGuiTestFrameWnd::CGuiTestFrameWnd()<br />
{<br />
	<br />
	Create( NULL, _T("Test"), WS_OVERLAPPEDWINDOW );<br />
	CMenu menu;<br />
	menu.LoadMenuA( MAKEINTRESOURCE(IDR_MENU1) );	<br />
	SetMenu( &menu );	 <br />
	<br />
	<br />
	MENUITEMINFO itmInfo;<br />
	//Here it doesn't work. It never enters in<br />
        //the block<br />
	if(menu.GetMenuItemInfo( 1, &itmInfo ))<br />
	{<br />
		itmInfo.fType |= MFT_OWNERDRAW;<br />
		menu.SetMenuItemInfo( 0, &itmInfo );<br />
	}<br />
<br />
	menu.Detach();<br />
		<br />
}<br />

AnswerRe: Setting a menu to OWNERDRAW Pin
Mark Salsbery13-Dec-06 6:02
Mark Salsbery13-Dec-06 6:02 
AnswerRe: Setting a menu to OWNERDRAW Pin
Hamid_RT13-Dec-06 18:18
Hamid_RT13-Dec-06 18:18 
Questionhow can i get CLSID from ProgID in managed c++ Pin
Banks K12-Dec-06 23:19
Banks K12-Dec-06 23:19 
AnswerRe: how can i get CLSID from ProgID in managed c++ Pin
Laxman Auti13-Dec-06 20:10
Laxman Auti13-Dec-06 20:10 
QuestionMFC Pin
Bravoone_200612-Dec-06 23:12
Bravoone_200612-Dec-06 23:12 
AnswerRe: MFC Pin
David Crow13-Dec-06 5:41
David Crow13-Dec-06 5:41 
AnswerRe: MFC Pin
Hamid_RT13-Dec-06 18:12
Hamid_RT13-Dec-06 18:12 
Questionabout MFC Pin
rajaasif12-Dec-06 23:04
rajaasif12-Dec-06 23:04 
AnswerRe: about MFC Pin
Rajesh R Subramanian12-Dec-06 23:18
professionalRajesh R Subramanian12-Dec-06 23:18 
AnswerRe: about MFC Pin
ShilpiP12-Dec-06 23:45
ShilpiP12-Dec-06 23:45 
AnswerRe: about MFC Pin
Hamid_RT13-Dec-06 0:20
Hamid_RT13-Dec-06 0:20 
AnswerRe: about MFC Pin
Maximilien13-Dec-06 3:42
Maximilien13-Dec-06 3:42 
QuestionHow edit the formicon and -text Pin
b43r_3oo312-Dec-06 22:23
b43r_3oo312-Dec-06 22:23 
QuestionHow to Set BackGround colors to a CProperty Sheet Tab Controls [modified] Pin
k. satheesh_1712-Dec-06 22:07
k. satheesh_1712-Dec-06 22:07 
AnswerRe: How to Set BackGround colors to a CProperty Sheet Tab Controls Pin
Mark Salsbery13-Dec-06 6:12
Mark Salsbery13-Dec-06 6:12 
AnswerRe: How to Set BackGround colors to a CProperty Sheet Tab Controls Pin
Hamid_RT13-Dec-06 18:09
Hamid_RT13-Dec-06 18:09 
QuestionA timed loop Pin
aquawicket12-Dec-06 22:05
aquawicket12-Dec-06 22:05 

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.