Click here to Skip to main content
16,011,358 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
GeneralRe: C++ Help Needed ( more info on it) Pin
Anatari7-Nov-02 10:38
Anatari7-Nov-02 10:38 
GeneralRe: C++ Help Needed ( more info on it) Pin
Anonymous7-Nov-02 11:05
Anonymous7-Nov-02 11:05 
GeneralRe: C++ Help Needed ( more info on it) Pin
Christian Graus7-Nov-02 12:04
protectorChristian Graus7-Nov-02 12:04 
GeneralRe: C++ Help Needed Pin
nde_plume7-Nov-02 13:23
nde_plume7-Nov-02 13:23 
Generaldialog Pin
Anonymous7-Nov-02 9:20
Anonymous7-Nov-02 9:20 
GeneralRe: dialog Pin
Anonymous7-Nov-02 9:24
Anonymous7-Nov-02 9:24 
GeneralRe: dialog Pin
Joaquín M López Muñoz7-Nov-02 9:24
Joaquín M López Muñoz7-Nov-02 9:24 
GeneralRe: dialog Pin
pnpfriend7-Nov-02 12:00
pnpfriend7-Nov-02 12:00 
yes.. GetNumbr() return CString. but the error is there.

here all the functions that I called.

mainDlg call both dlg1 and dlg2.
<br />
void mainDlg::ShowDlg1()<br />
{<br />
dlg2 d2;<br />
d2.DoModal(); // input number will be store after clicked OK<br />
// get the input number from dlg2 <br />
CString number = d2.GetNumber();//<font color = "navy">this is the place I got run time error.</font><br />
<br />
dlg1 d1;<br />
d1.SetTableNumber(number); // store input number for dlg1<br />
d1.DoModal(); //onintidialog() the input number will be display as static text on the dlg1.<br />
}<br />


dlg2 take input number(CString) from user.. it is very simple dialog. it has OK button and one EDIT BOX for the user to enter the number .
when the user click OK button, the input number will be stored
<br />
CString dlg2::GetNumber()<br />
{<br />
return inputNumber;<br />
} <br />
CString dlg2::OnOk()<br />
{<br />
inputNumber = m_inputNumber; <br />
CDialog::OK();<br />
}<br />
<br />

dlg1 take that number first. then when dialog is asked to display then display the input number on the dialog.
<br />
void dlg1::SetTableNumber(CString num)<br />
{<br />
m_tablenumber = num;<br />
}<br />
BOOL dlg1::OnInitDialog()<br />
{<br />
CDialog::OnInitDialog();<br />
.<br />
.<br />
.<br />
GetDlgItem(IDC_NUMBER)->SetWindowText(m_tablenumber);<br />
return 0;<br />
<br />
}<br />
<br />

GeneralRe: dialog Pin
Joaquín M López Muñoz7-Nov-02 12:05
Joaquín M López Muñoz7-Nov-02 12:05 
GeneralRe: dialog Pin
pnpfriend8-Nov-02 3:28
pnpfriend8-Nov-02 3:28 
GeneralC++ Help Needed Pin
Anonymous7-Nov-02 9:19
Anonymous7-Nov-02 9:19 
GeneralRe: C++ Help Needed Pin
Marc Clifton7-Nov-02 9:23
mvaMarc Clifton7-Nov-02 9:23 
QuestionMulti-View Single Doc example? Pin
Nick Jacobs7-Nov-02 9:10
Nick Jacobs7-Nov-02 9:10 
GeneralSAPI Pin
Anonymous7-Nov-02 9:14
Anonymous7-Nov-02 9:14 
Generalvirtual function confusion VTABLE Pin
ns7-Nov-02 8:47
ns7-Nov-02 8:47 
GeneralRe: virtual function confusion VTABLE Pin
Tim Smith7-Nov-02 8:51
Tim Smith7-Nov-02 8:51 
GeneralRe: virtual function confusion VTABLE Pin
ns7-Nov-02 8:59
ns7-Nov-02 8:59 
GeneralRe: virtual function confusion VTABLE Pin
Tim Smith7-Nov-02 10:03
Tim Smith7-Nov-02 10:03 
GeneralRe: virtual function confusion VTABLE Pin
Joaquín M López Muñoz7-Nov-02 8:48
Joaquín M López Muñoz7-Nov-02 8:48 
GeneralRe: virtual function confusion VTABLE Pin
ns7-Nov-02 9:02
ns7-Nov-02 9:02 
GeneralRe: virtual function confusion VTABLE Pin
Joaquín M López Muñoz7-Nov-02 9:04
Joaquín M López Muñoz7-Nov-02 9:04 
GeneralThank you! Pin
ns7-Nov-02 9:12
ns7-Nov-02 9:12 
GeneralToolbar tooltip question Pin
Stevenpph7-Nov-02 8:41
Stevenpph7-Nov-02 8:41 
GeneralRe: Toolbar tooltip question Pin
Joaquín M López Muñoz7-Nov-02 9:28
Joaquín M López Muñoz7-Nov-02 9:28 
GeneralRe: Toolbar tooltip question Pin
Stevenpph7-Nov-02 10:06
Stevenpph7-Nov-02 10:06 

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.