13.07.2015 Views

REFERENCE GUIDE

REFERENCE GUIDE

REFERENCE GUIDE

SHOW MORE
SHOW LESS

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

GetWindowToskAll applications are executed as tasks. Each instance of an application is atask.Parameters h Wnd HWND Identifies the window for which a task handle isretrieved.Return valueThe return value identifies the task associated with a particular window.GetWindowTextSyntaxint GetWindowText(hWnd,lpString, nMaxCount)function GetWindowText(Wnd: HWnd; Str: PChar; MaxCount: Integer):Integer;This function copies the given window's caption title (if it has one) intothe buffer pointed to by the IpString parameter. If the hWnd parameteridentifies a control, the GetWindowText function copies the text within thecontrol instead of copying the caption.Parameters h Wnd HWND Identifies the window or control whose caption ortext is to be copied.Return valueCommentsIpStringLPSTR Points to the buffer that is to receive the copiedstring.nMaxCount int Specifies the maximum number of characters to be copiedto the buffer. If the string is longer than the number ofcharacters specified in the nMaxCount parameter, it istruncated.The return value specifies the length of the copied string. It is zero if thewindow has no caption or if the caption is empty.This function causes a WM_ GETTEXT message to be sent to the givenwindow or control.GetWindowTextLengthSyntaxint GetWindowTextLength(hWnd)function GetWindowTextLength(Wnd: HWnd): Integer;This function returns the length of the given window's caption title. If theh Wnd parameter identifies a control, the GetWindowTextLength functionreturns the length of the text within the control instead of the caption.Parameters hWnd HWND Identifies the window or control.364 Software development kit

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!