Im trying to write some data to a text file. The text file would contain the logs & various data. Am using ofstream & whenever I write any datatype CString or LONG or anything, it writes in serialised form i guess.

I try to write as: tofile<<strValue;

But this is written to the file as some junk value. I want the text file to be readable when opened in notepad. I dont want to open the file from the application, and read those value, hence dont need serialization. How do i do?