Hi, I'm new to windows programming, and I'm trying to make it draw lines to wherever the user clicks. Right now I have this, and it works, but I think there must be a better way to send the message to WM_PAINT than passing -1 as the wParam.
hdc = GetDC(hWnd);
if(wParam == -1)
LineTo(hdc, LOWORD(lParam), HIWORD(lParam));
return DefWindowProc(hWnd, message, wParam, lParam);