I have a logging functionality and in this I have got log files. Now every time I run the program I want that previously written file should not get deleted and should be ap
maybe you need to open the file with the append option. like this:
FILE * pFile; pFile = fopen ("myfile.txt","a");
or this :
fstream filestr; filestr.open ("test.txt", fstream::app)