Show text file in edit box ? 
Author Message
 Show text file in edit box ?

Hi

I have an MFC dialog based app with an edit box, how do i get the contents
of a text file written with notepad to show in the edit box on start up ?

Thanks for any pointers
Malcolm



Fri, 27 Feb 2004 04:03:39 GMT  
 Show text file in edit box ?
Malcolm,

Take a look at the CStdioFile which you can use to open the file and read
one line at a time. For every line read, you add it to your edit ctrl.

--
Bjarne Nielsen



Quote:
> Hi

> I have an mfc dialog based app with an edit box, how do i get the contents
> of a text file written with notepad to show in the edit box on start up ?

> Thanks for any pointers
> Malcolm



Fri, 27 Feb 2004 05:10:50 GMT  
 Show text file in edit box ?
Thanks very much Bjarne :-)

Malcolm

Quote:
> Malcolm,

> Take a look at the CStdioFile which you can use to open the file and read
> one line at a time. For every line read, you add it to your edit ctrl.

> --
> Bjarne Nielsen



Sat, 28 Feb 2004 01:30:24 GMT  
 
 [ 3 post ] 

 Relevant Pages 

1. Showing Edit box text selected

2. How to show text in edit box?

3. Wrapping text in text box or edit box

4. Putting text into an Edit box from a file

5. list box text to edit box

6. Showing the correct value in edit box

7. how to show string, which I typed in edit box

8. Show individual digits in a read-only edit box

9. Showing a ASCII text on an Edit Control

10. Disabling editing of list box items in the file open dialog box

11. press enter in an edit box and make it happen in an other edit box too

12. Change the background color of a dialog box and change text color of Edit Box, Static Text, Rich Edit

 

 
Powered by phpBB® Forum Software