Click here to Skip to main content
15,923,083 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
GeneralRe: Please help me Pin
golden06062-Nov-03 16:09
golden06062-Nov-03 16:09 
Generalautorun USB memory sticks Pin
closecall2-Nov-03 13:53
closecall2-Nov-03 13:53 
GeneralProblem with CPropertyPage/Sheet Pin
el davo2-Nov-03 13:26
el davo2-Nov-03 13:26 
GeneralRe: Problem with CPropertyPage/Sheet Pin
Markyg2-Nov-03 14:56
Markyg2-Nov-03 14:56 
GeneralRe: Problem with CPropertyPage/Sheet Pin
Ravi Bhavnani2-Nov-03 15:00
professionalRavi Bhavnani2-Nov-03 15:00 
GeneralRe: Problem with CPropertyPage/Sheet Pin
el davo2-Nov-03 15:02
el davo2-Nov-03 15:02 
GeneralRe: Problem with CPropertyPage/Sheet Pin
Steve Mayfield2-Nov-03 15:01
Steve Mayfield2-Nov-03 15:01 
GeneralRe: Problem with CPropertyPage/Sheet Pin
Ravi Bhavnani2-Nov-03 15:07
professionalRavi Bhavnani2-Nov-03 15:07 
GeneralRe: Problem with CPropertyPage/Sheet Pin
Steve Mayfield4-Nov-03 9:20
Steve Mayfield4-Nov-03 9:20 
GeneralProblem with opening a file in editbox Pin
Deepak Samuel2-Nov-03 12:33
Deepak Samuel2-Nov-03 12:33 
GeneralRe: Problem with opening a file in editbox Pin
Christian Graus2-Nov-03 12:46
protectorChristian Graus2-Nov-03 12:46 
GeneralRe: Problem with opening a file in editbox Pin
Deepak Samuel2-Nov-03 12:55
Deepak Samuel2-Nov-03 12:55 
GeneralExiting Dialog to calling Dialog with data Pin
Karen03022-Nov-03 12:02
Karen03022-Nov-03 12:02 
GeneralRe: Exiting Dialog to calling Dialog with data Pin
Christian Graus2-Nov-03 12:11
protectorChristian Graus2-Nov-03 12:11 
GeneralRe: Exiting Dialog to calling Dialog with data Pin
Karen03022-Nov-03 12:18
Karen03022-Nov-03 12:18 
GeneralRe: Exiting Dialog to calling Dialog with data Pin
Christian Graus2-Nov-03 12:20
protectorChristian Graus2-Nov-03 12:20 
GeneralRe: Exiting Dialog to calling Dialog with data Pin
Karen03022-Nov-03 12:41
Karen03022-Nov-03 12:41 
GeneralRe: Exiting Dialog to calling Dialog with data Pin
Christian Graus2-Nov-03 12:44
protectorChristian Graus2-Nov-03 12:44 
GeneralRe: Exiting Dialog to calling Dialog with data Pin
Karen03022-Nov-03 12:59
Karen03022-Nov-03 12:59 
Ths is the code I am using to call the 2nd dialog;

TimeGet TimeGetDlg;
TimeGetDlg.DoModal();
if(TimeGetDlg.DoModal() == IDOK ) {
TG_AlarmHH= TimeGetDlg.HH;
TG_AlarmMM= TimeGetDlg.MM;
TG_AlarmAMPM= TimeGetDlg.AMPM;
}
and in the 2nd dialog, this is the overriden OK code;

void TimeGet::OnBnClickedOk()
{
CWnd* pWnd;
pWnd=GetDlgItem(IDC_HH);
pWnd->GetWindowText(HH);
pWnd=GetDlgItem(IDC_MM);
pWnd->GetWindowText(MM);
CDialog::OnOK();
}

What is happening is that when OK is clicked the first time, control returns to the 1st dialog at the if statement. The if fails and the 2nd dialog pops up again. This time when OK is clicked, control again returns to the if statement in the first dialog but this time the if succeeds and everything proceeds normally.

I have to admit that at this point I am totally lost.

Karen
GeneralRe: Exiting Dialog to calling Dialog with data Pin
Karen03022-Nov-03 13:02
Karen03022-Nov-03 13:02 
GeneralRe: Exiting Dialog to calling Dialog with data Pin
Christian Graus2-Nov-03 13:08
protectorChristian Graus2-Nov-03 13:08 
GeneralRe: Exiting Dialog to calling Dialog with data Pin
Karen03022-Nov-03 13:14
Karen03022-Nov-03 13:14 
GeneralRe: Exiting Dialog to calling Dialog with data Pin
Christian Graus2-Nov-03 13:15
protectorChristian Graus2-Nov-03 13:15 
GeneralRe: Exiting Dialog to calling Dialog with data Pin
Karen03023-Nov-03 2:05
Karen03023-Nov-03 2:05 
GeneralRe: Exiting Dialog to calling Dialog with data Pin
Christian Graus3-Nov-03 9:09
protectorChristian Graus3-Nov-03 9:09 

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.