I have a C++ windows API program which displays text using TextOut function
TCHAR buffer[] = _T("Hello");
TCHAR buffer1[] = _T("How to clear this one\?");
TextOut(hdc,200,170,buffer,_tcslen(buffer));
TextOut(hdc, 200, 185, buffer1, _tcslen(buffer1));
My further text output has been overwritten like this
how to clear the previous one and add this one.
I found that doing TextOut function on the same location like this
TextOut(hdc,200,170,buffer,_tcslen(buffer));
TextOut(hdc, 200, 170, buffer1, _tcslen(buffer1));
will replace the previous one but for some other reasons I cannot do this what is the actual way of clearing the screen. Is there anything in windows like system("cls") for console Thank you