1.
case WM_PAINT:
{
RECT rcClient;
PAINTSTRUCT ps;
HDC hdc = BeginPaint(hwnd, &ps);
ExtTextOut(hdcP, rt.left, rt.top, ETO, &rt, szText, _tcslen(szText), NULL);
EndPaint(hwnd, &ps);
}

2.call ValidateRect (hWnd,NUL,FALSE) ---- see MSDN