Help Center

AfxSetWindowTextfunction

Sets the text of a window.

WindowsfunctionAfxWin.incdoc-orphan
No implementation located. This member is documented, but the source scan found no matching declaration. It is likely declared in a header this scan does not resolve, or provided by a macro.

Syntax

FUNCTION AfxSetWindowText (BYVAL hwnd AS HWND, BYVAL pwszText AS WSTRING PTR) AS BOOLEAN

Parameters

NameDescription
hwndHandle to the window.
pwszTextThe text to set.

Return value

If the function succeeds, the return value is TRUE.

If the function fails, the return value is FALSE.

Description

Sets the text of a window. This function can also be used to set the text of buttons, edit and static controls.

Reference

  • Include file AfxWin.inc
  • Documented in Windows/Windows Procedures.md
  • Topic: Windows Procedures