How to add text at the last of the file using c++? : I am currently working on project and I need solution of that.I want to add some message at the end of file and also I want to change its extension. Since my programming skills are not so good please give syntax of that.