markpasc.blog: "And how is one supposed to read from an edit box in a non-MFC C++ program, eh? Guh."
Reading from an edit box without using MFC is done by sending it a message. If the editbox HWND is stored in hWnd, the code below does it: long len = SendMessage(hWnd, WM_GETTEXTLENGTH, 0, 0);
char* buffer = malloc(len);
SendMessage(hWnd, WM_GETTEXT, len, buffer);
I believe this will only work if the length is less than 32K though.
10:14:26 AM
|