Click here to Skip to main content
15,908,661 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
GeneralRe: Modal dialog with MSFlexGrid is not opening Pin
Cool_Dev20-Aug-10 2:35
Cool_Dev20-Aug-10 2:35 
QuestionWhere to get VC8 Debug CRT 8.0.50727.4053 [Moved] Pin
VC_RYK19-Aug-10 23:14
VC_RYK19-Aug-10 23:14 
AnswerRe: Where to get VC8 Debug CRT 8.0.50727.4053 Pin
Nish Nishant20-Aug-10 6:31
sitebuilderNish Nishant20-Aug-10 6:31 
QuestionFile stream reading Pin
ganesh_IT19-Aug-10 22:55
ganesh_IT19-Aug-10 22:55 
QuestionRe: File stream reading PinPopular
CPallini19-Aug-10 23:55
mveCPallini19-Aug-10 23:55 
Questiononlick event of command button is not called Pin
ganesh.dp19-Aug-10 21:55
ganesh.dp19-Aug-10 21:55 
AnswerRe: onlick event of command button is not called Pin
CPallini19-Aug-10 23:57
mveCPallini19-Aug-10 23:57 
AnswerRe: onlick event of command button is not called Pin
norish21-Aug-10 13:58
norish21-Aug-10 13:58 
Assign unique value for duplicated id, simply.
You should assign all unique (different) id for different controls.
Only one handler will be called for one id value on MFC message mapping.
Because MFC's message mapping is very simple implement which using array of struct,
and decide handler by sequential searching.

When message map is as below;
BEGIN_MESSAGE_MAP(CSampleDlg, CDialog)
	//{{AFX_MSG_MAP(CSampleDlg)
	ON_BN_CLICKED(IDC_BUTTON1, OnButton1)
	ON_BN_CLICKED(IDC_BUTTON2, OnButton2)
	//}}AFX_MSG_MAP
END_MESSAGE_MAP()

Compiler recognize as below; (rewriting simply)
struct MessageEntry messageEntries[] = {
    { IDC_BUTTON1, OnButton1 },
    { IDC_BUTTON2, OnButton2 }
};

If IDC_BUTTON1 and IDC_BUTTON2 are equal, the sequential searching algorithm always find OnButton1 for IDC_BUTTON{1,2}.
QuestionHow can we create Unlimited number of controls at runtime? Pin
rahul.kulshreshtha19-Aug-10 20:26
rahul.kulshreshtha19-Aug-10 20:26 
AnswerRe: How can we create Unlimited number of controls at runtime? Pin
Cedric Moonen19-Aug-10 20:45
Cedric Moonen19-Aug-10 20:45 
GeneralRe: How can we create Unlimited number of controls at runtime? Pin
rahul.kulshreshtha19-Aug-10 21:18
rahul.kulshreshtha19-Aug-10 21:18 
GeneralRe: How can we create Unlimited number of controls at runtime? Pin
Emilio Garavaglia19-Aug-10 22:14
Emilio Garavaglia19-Aug-10 22:14 
GeneralRe: How can we create Unlimited number of controls at runtime? Pin
Niklas L19-Aug-10 22:36
Niklas L19-Aug-10 22:36 
GeneralRe: How can we create Unlimited number of controls at runtime? Pin
rahul.kulshreshtha19-Aug-10 22:43
rahul.kulshreshtha19-Aug-10 22:43 
GeneralRe: How can we create Unlimited number of controls at runtime? Pin
Emilio Garavaglia20-Aug-10 1:42
Emilio Garavaglia20-Aug-10 1:42 
GeneralRe: How can we create Unlimited number of controls at runtime? Pin
Niklas L20-Aug-10 2:02
Niklas L20-Aug-10 2:02 
AnswerRe: How can we create Unlimited number of controls at runtime? Pin
Niklas L19-Aug-10 22:07
Niklas L19-Aug-10 22:07 
QuestionNM_EVENT is not being called Pin
learningvisualc19-Aug-10 20:23
learningvisualc19-Aug-10 20:23 
QuestionSocket based application and Anti-viruses Pin
rahul.kulshreshtha19-Aug-10 19:59
rahul.kulshreshtha19-Aug-10 19:59 
AnswerRe: Socket based application and Anti-viruses Pin
Richard MacCutchan19-Aug-10 22:41
mveRichard MacCutchan19-Aug-10 22:41 
AnswerRe: Socket based application and Anti-viruses Pin
Moak20-Aug-10 2:37
Moak20-Aug-10 2:37 
AnswerRe: Socket based application and Anti-viruses Pin
CPallini20-Aug-10 3:05
mveCPallini20-Aug-10 3:05 
QuestionComBoBox:SetCurSel & GetCurSel() Pin
Anu_Bala19-Aug-10 18:14
Anu_Bala19-Aug-10 18:14 
AnswerRe: ComBoBox:SetCurSel & GetCurSel() Pin
Cool_Dev19-Aug-10 19:28
Cool_Dev19-Aug-10 19:28 
GeneralRe: ComBoBox:SetCurSel & GetCurSel() Pin
Anu_Bala19-Aug-10 19:31
Anu_Bala19-Aug-10 19:31 

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.