Group: Window - Library: user32
This function is similar to the GetWindowText function. However, it obtains the window text directly from the window structure associated with the specified window"s handle and then always provides the text as a unicode string.
Simple Window Viewer
Scanning the hierarchy of child windows down from the main VFP window
int InternalGetWindowText(
HWND hWnd,
LPWSTR lpString,
int nMaxCount
);
DECLARE INTEGER InternalGetWindowText IN user32;
INTEGER hWnd,;
STRING @ lpString,;
INTEGER nMaxCount
hWnd [in] Handle to the window or control containing the text.
lpString [out] Pointer to the wide character buffer that receives the text.
nMaxCount [in] Specifies the maximum number of characters to copy to the buffer, including the NULL character.
If the function succeeds, the return value is the length, in characters, of the copied string, not including the terminating NULL character.
MSDN: This is unlike GetWindowText which obtains the text by sending the window a WM_GETTEXT message. If the specified window is a control, the text of the control is obtained.