Click here to Skip to main content
15,900,511 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
GeneralRe: Crashes no matter where Pin
12-Jun-01 0:26
suss12-Jun-01 0:26 
GeneralRe: Program crashes when I try to assign values to a CListBox in a dialog window created from my main dialog window Pin
Ulf Öhlén12-Jun-01 0:16
Ulf Öhlén12-Jun-01 0:16 
GeneralRe: Program crashes when I try to assign values to a CListBox in a dialog window created from my main dialog window Pin
12-Jun-01 0:24
suss12-Jun-01 0:24 
GeneralNot quite what I do. Pin
12-Jun-01 0:34
suss12-Jun-01 0:34 
GeneralRe: Not quite what I do. Pin
Ulf Öhlén12-Jun-01 0:59
Ulf Öhlén12-Jun-01 0:59 
GeneralNope, that didn't work Pin
12-Jun-01 11:19
suss12-Jun-01 11:19 
GeneralRe: Nope, that didn't work Pin
Ulf Öhlén12-Jun-01 23:19
Ulf Öhlén12-Jun-01 23:19 
GeneralRe: Not quite what I do. Pin
Michael P Butler12-Jun-01 22:39
Michael P Butler12-Jun-01 22:39 
GeneralLPT Port IO In Win2k Pin
Joseph LeBlanc11-Jun-01 15:54
Joseph LeBlanc11-Jun-01 15:54 
GeneralChar value for line break in an Edit Box Pin
11-Jun-01 14:26
suss11-Jun-01 14:26 
GeneralRe: Char value for line break in an Edit Box Pin
11-Jun-01 14:45
suss11-Jun-01 14:45 
GeneralRe: Char value for line break in an Edit Box Pin
Michael Dunn11-Jun-01 16:29
sitebuilderMichael Dunn11-Jun-01 16:29 
GeneralTHANK YOU Pin
11-Jun-01 17:57
suss11-Jun-01 17:57 
GeneralRe: THANK YOU Pin
Ben Burnett11-Jun-01 19:30
Ben Burnett11-Jun-01 19:30 
GeneralDocking Windows and MDI Pin
Jamie Nordmeyer11-Jun-01 12:17
Jamie Nordmeyer11-Jun-01 12:17 
GeneralCreating controls in the client area Pin
Waleed Eissa11-Jun-01 10:40
Waleed Eissa11-Jun-01 10:40 
GeneralRe: Creating controls in the client area Pin
Igor Sukhov11-Jun-01 22:56
Igor Sukhov11-Jun-01 22:56 
QuestionDeleting folders with SHFileOperation? Pin
Jim A. Johnson11-Jun-01 9:50
Jim A. Johnson11-Jun-01 9:50 
AnswerRe: Deleting folders with SHFileOperation? Pin
Jim A. Johnson12-Jun-01 5:55
Jim A. Johnson12-Jun-01 5:55 
GeneralAdding resource(bitmap) in run-time. Pin
11-Jun-01 9:26
suss11-Jun-01 9:26 
GeneralRe: Adding resource(bitmap) in run-time. Pin
Igor Sukhov11-Jun-01 9:32
Igor Sukhov11-Jun-01 9:32 
GeneralAbout VC++ 7.0 ... Pin
Hadi Rezaee11-Jun-01 7:05
Hadi Rezaee11-Jun-01 7:05 
GeneralRe: About VC++ 7.0 ... Pin
2sky11-Jun-01 7:54
2sky11-Jun-01 7:54 
GeneralCarriage return/Line feed Pin
RobJones11-Jun-01 6:34
RobJones11-Jun-01 6:34 
Hello,
I’m trying to write 3 strings out to a text file but I need each string to be on a separate line.. Here is what I have tried..

CFile fileEditText;

if(fileEditText.Open("c:\\text.txt",
CFile::modeCreate + CFile::modeWrite))
{
//Write out the full string
fileEditText.Write(
strFirstline+"\n\r"+strSecondline+"\n\r"+strThird+"\n\r",length.GetLength());
//Close the file
fileEditText.Close();
}

I've tried every combo of "\n" "\r" etc..

It still writes out the 3 strings in one continuous line in the text file..

Any help would be appreciated.

THANKS,
Confused | :confused:

Rob
GeneralRe: Carriage return/Line feed Pin
Michael Dunn11-Jun-01 6:39
sitebuilderMichael Dunn11-Jun-01 6:39 

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.