To hold the window handle of the edit control, create a global variable. To do this, add the following statement to the beginning of the C-language source file:
HWND hEditWnd /* handle of edit window */
You must also create a local variable in the WinMain function to hold the coordinates of the client area rectangle. These coordinates are used to determine the size of the control. To do this, add the following statement to the beginning of the WinMain function:
RECT
Rect;