I am trying to put text on a sdi program. here is an example of what I am doing:

CClientDC cdc(this);
CString mess;
mess.format("a message here");
cdc.textout(10,10,mess);

Now here is my problem, it prints it out to the screen, but if another window covers it, the text vanishes, and also if I want to put something else there I have to print out to that spot twice once with a really long empty string and then again with what I want there. Is there a way to keep the text there when another window covers it? And is it possible to have like a Clear Document command of some sort?

Thanks for the help in advance.