Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

Categories

C++prog,for editing text files!can anyone help?

I am working on a C++ prog. that edits text files by replacing all occurrences of a phrase with another one.I need to get 4 pieces of data from the user.Name of file,name of file to save to,phrase to replace,new phrase. Inform user once edited text is saved and how many occurrences have been replaced. I am new at C++ and have only a general knowledge on how to make this work. Can anyone help??Please!!!

Comments

  • Geeth AsokanGeeth Asokan Member Posts: 127
    : I am working on a C++ prog. that edits text files by replacing all occurrences of a phrase with another one.I need to get 4 pieces of data from the user.Name of file,name of file to save to,phrase to replace,new phrase. Inform user once edited text is saved and how many occurrences have been replaced. I am new at C++ and have only a general knowledge on how to make this work. Can anyone help??Please!!!
    :

    Hi,

    You could do this using the theory of [b]file I/O[/b], using the header file [b]#include [/b], together with the functions [b]fstream[/b] and [b]ofstream[/b].

  • Justin BibJustin Bib USAMember Posts: 0

    _ / http://forcoder.org / free ebooks and video tutorials about | Swift, Python, Visual Basic .NET, Go, Scratch, Objective-C, C#, JavaScript, Visual Basic, MATLAB, Java, PL/SQL, Perl, Delphi, Ruby, C++, R, C, Assembly, PHP Scala, Fortran, Dart, Ada, Prolog, Apex, Lisp, Hack, Alice, FoxPro, Bash, Awk, Rust, VBScript, Transact-SQL, LabVIEW, COBOL, Erlang, Logo, Julia, F#, SAS, Kotlin, ABAP, Lua, Scheme, ML, Clojure, D, Crystal | ___

Sign In or Register to comment.