I am trying to create a log so that i can monitor statistics in the program im running.
Ive successfully set up the Richedit control and everything, i was wondering if someone could explain to me how I could actually add data to it, also if someone could explain how i could format the data (change color, size, bold, italics) and how i could save all the data to a .txt file.
I have the file stream code set up:
Code:
case LOG_BUTTON_SAVE:
{
SaveFile(hWnd); //Just an Open Save Dialog Function - Ignore
char *Buffer = new char[1000];
//**saving code goes here**
ofstream fout;
fout.open(FileName, ios::ate);
fout << Buffer;
fout.close();
if (Buffer)
delete[] Buffer;
break;
}
I was wondering which message I would have to send to the Richedit control in order to get its contents into the Buffer i declared in the code above.
Thanks
PaYnE