Click here to Skip to main content
15,891,633 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
AnswerRe: Create process & IE Pin
Chuck O'Toole16-Feb-12 4:35
Chuck O'Toole16-Feb-12 4:35 
QuestionTCP/IP socket timeout per connection Pin
vikramlinux13-Feb-12 4:17
vikramlinux13-Feb-12 4:17 
AnswerRe: TCP/IP socket timeout per connection Pin
Albert Holguin13-Feb-12 4:38
professionalAlbert Holguin13-Feb-12 4:38 
GeneralRe: TCP/IP socket timeout per connection Pin
vikramlinux13-Feb-12 4:44
vikramlinux13-Feb-12 4:44 
GeneralRe: TCP/IP socket timeout per connection Pin
Albert Holguin13-Feb-12 6:22
professionalAlbert Holguin13-Feb-12 6:22 
GeneralRe: TCP/IP socket timeout per connection Pin
vikramlinux13-Feb-12 22:27
vikramlinux13-Feb-12 22:27 
QuestionHow to re-use the replace() function to replace different strings in the same file ? Pin
Faez Shingeri13-Feb-12 0:12
Faez Shingeri13-Feb-12 0:12 
AnswerRe: How to re-use the replace() function to replace different strings in the same file ? Pin
Luc Pattyn13-Feb-12 2:36
sitebuilderLuc Pattyn13-Feb-12 2:36 
Your file names are constant strings, defined inside your function. That is not the way to do it.

I see basically two ways that could work for you:

1.
perform all replace operations in memory, not in files. That way you can load a text file, modify the text as much as you want, then store the final text in the same or in another file.

2.
make the source and destination file names input parameters to your function, and use a new destination file name each time you call replace().

Smile | :)

PS: why are you rewinding the files before closing them?
Luc Pattyn [My Articles] Nil Volentibus Arduum

Fed up by FireFox memory leaks I switched to Opera and now CP doesn't perform its paste magic, so links will not be offered. Sorry.

GeneralRe: How to re-use the replace() function to replace different strings in the same file ? Pin
David Crow13-Feb-12 2:43
David Crow13-Feb-12 2:43 
GeneralRe: How to re-use the replace() function to replace different strings in the same file ? Pin
Faez Shingeri13-Feb-12 18:33
Faez Shingeri13-Feb-12 18:33 
GeneralRe: How to re-use the replace() function to replace different strings in the same file ? Pin
David Crow14-Feb-12 3:13
David Crow14-Feb-12 3:13 
GeneralRe: How to re-use the replace() function to replace different strings in the same file ? Pin
Faez Shingeri14-Feb-12 16:58
Faez Shingeri14-Feb-12 16:58 
QuestionRe: How to re-use the replace() function to replace different strings in the same file ? Pin
David Crow15-Feb-12 3:01
David Crow15-Feb-12 3:01 
QuestionWrite a C/C++ program that connects to a MySQL server and displays the global TIMEZONE Pin
manmadkumarreddy12-Feb-12 7:50
manmadkumarreddy12-Feb-12 7:50 
AnswerRe: Write a C/C++ program that connects to a MySQL server and displays the global TIMEZONE Pin
Richard Andrew x6412-Feb-12 7:55
professionalRichard Andrew x6412-Feb-12 7:55 
AnswerRe: Write a C/C++ program that connects to a MySQL server and displays the global TIMEZONE Pin
Richard MacCutchan12-Feb-12 8:12
mveRichard MacCutchan12-Feb-12 8:12 
AnswerRe: Write a C/C++ program that connects to a MySQL server and displays the global TIMEZONE Pin
Mohibur Rashid12-Feb-12 18:04
professionalMohibur Rashid12-Feb-12 18:04 
AnswerRe: Write a C/C++ program that connects to a MySQL server and displays the global TIMEZONE Pin
Wes Aday13-Feb-12 3:03
professionalWes Aday13-Feb-12 3:03 
QuestionI need gSpan source code ( C or C++ ) Pin
linnumberone12-Feb-12 1:31
linnumberone12-Feb-12 1:31 
AnswerRe: I need gSpan source code ( C or C++ ) Pin
Richard MacCutchan12-Feb-12 1:41
mveRichard MacCutchan12-Feb-12 1:41 
GeneralRe: I need gSpan source code ( C or C++ ) Pin
linnumberone12-Feb-12 1:48
linnumberone12-Feb-12 1:48 
GeneralRe: I need gSpan source code ( C or C++ ) Pin
Richard MacCutchan12-Feb-12 3:04
mveRichard MacCutchan12-Feb-12 3:04 
GeneralRe: I need gSpan source code ( C or C++ ) Pin
linnumberone12-Feb-12 3:31
linnumberone12-Feb-12 3:31 
GeneralRe: I need gSpan source code ( C or C++ ) Pin
linnumberone12-Feb-12 3:53
linnumberone12-Feb-12 3:53 
GeneralRe: I need gSpan source code ( C or C++ ) Pin
Albert Holguin12-Feb-12 9:13
professionalAlbert Holguin12-Feb-12 9:13 

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.