Click here to Skip to main content
15,927,060 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
GeneralRe: CArchive - Reading strings Pin
Ravi Bhavnani10-Feb-04 2:44
professionalRavi Bhavnani10-Feb-04 2:44 
GeneralMemory Leak Finder Pin
[James Pullicino]9-Feb-04 4:09
[James Pullicino]9-Feb-04 4:09 
GeneralRe: Memory Leak Finder Pin
Rickard Andersson209-Feb-04 4:29
Rickard Andersson209-Feb-04 4:29 
GeneralRe: Memory Leak Finder Pin
Alexander M.,9-Feb-04 7:25
Alexander M.,9-Feb-04 7:25 
QuestionHow to use RegSaveKey? Pin
Anonymous9-Feb-04 3:45
Anonymous9-Feb-04 3:45 
AnswerRe: How to use RegSaveKey? Pin
David Crow9-Feb-04 5:33
David Crow9-Feb-04 5:33 
GeneralData from one dlg to another Pin
Ashman9-Feb-04 3:21
Ashman9-Feb-04 3:21 
GeneralRe: Data from one dlg to another Pin
Michael P Butler9-Feb-04 3:31
Michael P Butler9-Feb-04 3:31 
Ashman wrote:
dlg.DoModal();
dlg.SetDlgItemText(IDC_INVOICE, _T(invoicenumber));


The call to dlg.DoModal will show the dialog and therefore any further code in your function won't be executed until the dialog is closed.

You'll need to pass the CString into your class before DoModal and then inside the WM_INITDIALOG handler, set the window text of the control.

e.g

<br />
void CInvoice::OnTender() <br />
{<br />
// TODO: Add your control notification handler code here<br />
CString invoicenumber;<br />
GetDlgItemText(IDC_INVOICENO,invoicenumber);<br />
CTender dlg;<br />
<br />
dlg.m_strInvoiceNo = invoiceNumber;<br />
<br />
dlg.DoModal();<br />
<br />
<br />
}<br />
<br />
BOOL CTender::OnInitDialog()<br />
{<br />
   CDialog::OnInitDialog();<br />
<br />
   m_invoiceme.SetWindowText(m_strInvoiceNo);<br />
<br />
}<br />
<br />
<br />
<br />



Michael

But you know when the truth is told,
That you can get what you want or you can just get old,
Your're going to kick off before you even get halfway through.
When will you realise... Vienna waits for you?
- "The Stranger," Billy Joel
GeneralHello Help pls !!! Multiple View for a document .. Pin
itmpras9-Feb-04 2:38
itmpras9-Feb-04 2:38 
GeneralRe: Hello Help pls !!! Multiple View for a document .. Pin
Michael P Butler9-Feb-04 3:35
Michael P Butler9-Feb-04 3:35 
GeneralProblems by getting current sel Item - Outlook Pin
johnxx9-Feb-04 2:36
johnxx9-Feb-04 2:36 
GeneralRe: Problems by getting current sel Item - Outlook Pin
johnxx9-Feb-04 5:32
johnxx9-Feb-04 5:32 
GeneralScrollBar on MCIWindows Pin
Member 5252199-Feb-04 1:44
Member 5252199-Feb-04 1:44 
Questionhelp!~Who can show a code of simulate network server? Pin
artliu5209-Feb-04 0:27
artliu5209-Feb-04 0:27 
AnswerRe: help!~Who can show a code of simulate network server? Pin
Ravi Bhavnani9-Feb-04 2:23
professionalRavi Bhavnani9-Feb-04 2:23 
AnswerRe: help!~Who can show a code of simulate network server? Pin
Muthukumar10-Feb-04 17:40
Muthukumar10-Feb-04 17:40 
AnswerRe: help!~Who can show a code of simulate network server? Pin
Anonymous11-Feb-04 17:04
Anonymous11-Feb-04 17:04 
GeneralCDialog and CEdit Problem Pin
el_scrub8-Feb-04 23:49
el_scrub8-Feb-04 23:49 
GeneralRe: CDialog and CEdit Problem Pin
9-Feb-04 1:42
suss9-Feb-04 1:42 
QuestionThread Tutorial? Pin
Member 3350228-Feb-04 23:01
Member 3350228-Feb-04 23:01 
AnswerRe: Thread Tutorial? Pin
Member 5252199-Feb-04 1:46
Member 5252199-Feb-04 1:46 
AnswerRe: Thread Tutorial? Pin
Ravi Bhavnani9-Feb-04 2:25
professionalRavi Bhavnani9-Feb-04 2:25 
AnswerRe: Thread Tutorial? Pin
David Crow9-Feb-04 5:37
David Crow9-Feb-04 5:37 
Questiondisplaying tooltips? Pin
j3ves8-Feb-04 23:01
j3ves8-Feb-04 23:01 
AnswerRe: displaying tooltips? Pin
Ravi Bhavnani9-Feb-04 2:26
professionalRavi Bhavnani9-Feb-04 2:26 

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.