Click here to Skip to main content
15,898,134 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
QuestionCStdIOFile ???? Pin
Shay Harel27-Dec-04 4:24
Shay Harel27-Dec-04 4:24 
AnswerRe: CStdIOFile ???? Pin
4apai27-Dec-04 5:39
4apai27-Dec-04 5:39 
GeneralRe: CStdIOFile ???? Pin
Shay Harel27-Dec-04 5:42
Shay Harel27-Dec-04 5:42 
GeneralRe: CStdIOFile ???? Pin
4apai27-Dec-04 5:45
4apai27-Dec-04 5:45 
AnswerRe: CStdIOFile ???? Pin
Wes Aday27-Dec-04 8:53
professionalWes Aday27-Dec-04 8:53 
GeneralRe: CStdIOFile ???? Pin
Shay Harel27-Dec-04 8:55
Shay Harel27-Dec-04 8:55 
GeneralRe: CStdIOFile ???? Pin
Wes Aday27-Dec-04 9:00
professionalWes Aday27-Dec-04 9:00 
AnswerRe: CStdIOFile ???? Pin
Tom Wright27-Dec-04 8:54
Tom Wright27-Dec-04 8:54 
Here's whay I do and it works everytime.

<br />
       	CStdioFile myFile;<br />
	myFile.Open (FileName, CFile::modeCreate |                 CFile::modeReadWrite | CFile::modeNoTruncate, NULL);<br />
	myFile.SeekToEnd();<br />
	myFile.WriteString (strLSbuf);<br />
	myFile.Close ();<br />


I think the problem you are running into is that you are not first placing the cursor to the end of the line then writing out your string.

So when you do an open on the file, the cursor is placed at the beginning of the line and you overwrite your existing data.

Hope this help


Tom Wright
tawright915@yahoo.com
GeneralRe: CStdIOFile ???? Pin
Shay Harel27-Dec-04 9:00
Shay Harel27-Dec-04 9:00 
GeneralAbout MAP Pin
LiYS27-Dec-04 4:02
LiYS27-Dec-04 4:02 
QuestionHow Can I Draw Inside a Edit Ctrl? Pin
SivaramanDhamodharan27-Dec-04 1:17
SivaramanDhamodharan27-Dec-04 1:17 
AnswerRe: How Can I Draw Inside a Edit Ctrl? Pin
Azghar Hussain27-Dec-04 4:21
professionalAzghar Hussain27-Dec-04 4:21 
GeneralRe: How Can I Draw Inside a Edit Ctrl? Pin
SivaramanDhamodharan27-Dec-04 18:18
SivaramanDhamodharan27-Dec-04 18:18 
QuestionHow to find a Active or Highlighted or Default Button in a given Window Pin
sureei26-Dec-04 23:51
sureei26-Dec-04 23:51 
AnswerRe: How to find a Active or Highlighted or Default Button in a given Window Pin
ThatsAlok27-Dec-04 1:08
ThatsAlok27-Dec-04 1:08 
GeneralCase of Characters (PreTranslateMessage) Pin
Grahamfff26-Dec-04 23:40
Grahamfff26-Dec-04 23:40 
GeneralRe: Case of Characters (PreTranslateMessage) Pin
Neville Franks27-Dec-04 10:24
Neville Franks27-Dec-04 10:24 
GeneralWindows Server 2003 DDK Pin
RedDragon2k26-Dec-04 23:28
RedDragon2k26-Dec-04 23:28 
GeneralIterate through controls on Dialog Box Pin
Mandar D. Sahasrabuddhe26-Dec-04 22:58
professionalMandar D. Sahasrabuddhe26-Dec-04 22:58 
GeneralRe: Iterate through controls on Dialog Box Pin
4apai27-Dec-04 5:53
4apai27-Dec-04 5:53 
GeneralRe: Iterate through controls on Dialog Box Pin
User 665827-Dec-04 6:38
User 665827-Dec-04 6:38 
GeneralRe: Iterate through controls on Dialog Box Pin
Mandar D. Sahasrabuddhe31-Dec-04 0:21
professionalMandar D. Sahasrabuddhe31-Dec-04 0:21 
GeneralNot quite understand TRACKMOUSEEVENT &amp; _TrackMouseEvent() Pin
LiYS26-Dec-04 22:41
LiYS26-Dec-04 22:41 
GeneralRe: Not quite understand TRACKMOUSEEVENT &amp; _TrackMouseEvent() Pin
User 665827-Dec-04 6:16
User 665827-Dec-04 6:16 
GeneralCommunicate with USB device Pin
ty cheng26-Dec-04 20:25
ty cheng26-Dec-04 20:25 

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.