my app reads a text file and writes to a database. How do I use Edit control to tell or display in my window about the status of my application (ie) reading the text file now, now writing into database
Printable View
my app reads a text file and writes to a database. How do I use Edit control to tell or display in my window about the status of my application (ie) reading the text file now, now writing into database
Attach a var to you CEdit control. Then add the text to the var eg.
m_edit = "Writing Data";
UpdateData( FALSE );
Simple,
Define a variable of CString type , which maps to the Edit control, thru the class wizard.
The when you are calling the read from text file function, assign some text to the CString Variable and call UpdateData(FALSE) , this will show the text on the edit box. do this for the save database function also.
The code for this could be :
CString strShowText; // declared in the header file
then when the function is called:
strShowText = "Blah, Blah, .....";
UpdateData(FALSE);