|
[x]
Posted via EE Mobile
|
||
Search, ask, and monitor your questions on the go with EE Mobile. Visit Experts Exchange from your mobile device and never be out of touch again. |
||
| 10/15/2009 at 10:57PM PDT, ID: 24817264 | Points: 500 |
|
[x]
Attachment Details
|
||
1: 2: 3: 4: 5: 6: 7: 8: 9: 10: 11: 12: 13: 14: 15: 16: 17: 18: 19: 20: 21: 22: 23: 24: 25: 26: 27: 28: 29: 30: 31: 32: 33: 34: 35: 36: 37: 38: 39: 40: 41: 42: 43: 44: 45: 46: 47: 48: 49: 50: 51: 52: 53: 54: 55: 56: 57: 58: 59: 60: 61: 62: 63: 64: 65: 66: 67: 68: 69: 70: 71: 72: 73: 74: 75: 76: 77: 78: 79: 80: 81: 82: 83: 84: 85: 86: 87: 88: 89: 90: 91: 92: 93: 94: 95: 96: 97: 98: 99: 100: 101: 102: 103: 104: 105: 106: 107: 108: 109: 110: 111: 112: 113: 114: 115: 116: 117: 118: 119: 120: 121: 122: 123: 124: 125: 126: 127: 128: |
//IP SetupDlg.cpp ==Main Dialog file
#include "IP Setup.h"
#include "IP SetupDlg.h"
#include "Dlg_1.h"
//Main Dialog it never appears
BOOL IPSetupDlg::OnInitDialog()
{
CDialog::OnInitDialog();
EndDialog(TRUE);
CDlg_1 Dlg;
Dlg.DoModal();
return TRUE;
}
///////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
//Dlg_1.cpp
#include "IP Setup.h"
#include "IP SetupDlg.h"
#include "Dlg_1.h"
//#include "Dlg_2.h" //ATTENTION Dlg_2 becomes Step 3 (Dlg_3)
#include "dlg_3.h" // ATTENTION Dlg_3 is now Step 2 (Dlg_2)
void CDlg_1::OnNext()
{
// TODO: Add your control notification handler code here
UpdateData(TRUE);
GetDlgItem(IDNEXT)->EnableWindow(false);
CWaitCursor();
EndDialog(TRUE);
//CDlg_2 Dlg2; //ATTENTION Dlg_2 become Step 3 (Dlg_3)
//Dlg2.DoModal();
Cdlg_3 dlg3; //ATTENTION Dlg_3 is now Step 2 (Dlg_2)
dlg3.DoModal();
return; // Dialog closed and DoModal returns only here! When using EndDialog()
}
///////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
//Dlg_3.cpp == in fact Dlg_3 and Dlg_2 are switched , so Dlg_3 is the Step 2 and Dlg_2 is the //last Step 3
#include "IP Setup.h"
#include "dlg_3.h"
#include "Dlg_2.h"
#include "Dlg_1.h"
void Cdlg_3::OnSave() //In fact it is a Next button
{
// TODO: Add your control notification handler code here
UpdateData(TRUE);
CWaitCursor();
m_label_wait.SetWindowText("Please wait...");
....
....
FreeLibrary(hDLLCOMBO5);
Sleep(10);
ShowWindow(SW_HIDE);
UpdateData(FALSE);
EndDialog(TRUE);
CDlg_2 Dlg2;
Dlg2.DoModal();
return; // Dialog closed and DoModal returns only here! When using EndDialog()
}
void Cdlg_3::OnPreview()
{
// TODO: Add your control notification handler code here
UpdateData(TRUE);
....
....
EndDialog(TRUE);
CDlg_1 Dlg1;
Dlg1.DoModal();
return;
//DestroyWindow();
}
///////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
//Dlg_2.cpp == this is in fact the last step 3 (Dlg_3)
#include "IP Setup.h"
#include "IP SetupDlg.h"
#include "Dlg_2.h"
#include "dlg_3.h"
#include "Dlg_1.h"
void CDlg_2::OnNext() //Dlg_2 contains only this button to close the program
{
// TODO: Add your control notification handler code here
UpdateData(TRUE);
EndDialog(TRUE);
//Cdlg_3 dlg3; //090924
//dlg3.DoModal(); //099024
OnOK(); //Close the program
}
void CDlg_2::OnPreview() //this button is not pushed, it is a not visible control
//because in step 3 we can't go back and there are only the next
//button to close the program
{
// TODO: Add your control notification handler code here
UpdateData(TRUE);
KillTimer(3);
EndDialog(TRUE); //091002 BUG
CDlg_1 Dlg1;
Dlg1.DoModal();
return;
}
|
Advertisement