The basic answer is "send the control a window message". Unfortunately, I'm not a Win32 guru, so I can't just whip up the code out of thin air, and my copy of Petzold is at the house, but there's a Win32 API call you'll use:
Code:
lResult = SendMessage( // returns LRESULT in lResult
(HWND) hWndControl, // handle to destination control
(UINT) EM_SETTEXTEX, // message ID
(WPARAM) wParam, // = (WPARAM) () wParam;
(LPARAM) lParam // = (LPARAM) () lParam; );
Where hWnd is the window handle of the control, wParam points to a SETTEXTEX structure:
Code:
typedef struct _settextex {
DWORD flags;
UINT codepage;}
SETTEXTEX;
and lParam is a pointer to a typical C-style string.