Show: Delphi C++
Display Preferences

Vcl.Controls.TControl.SetTextBuf

From RAD Studio API Documentation
Jump to: navigation, search

Delphi

procedure SetTextBuf(Buffer: PChar);

C++

void __fastcall SetTextBuf(System::WideChar * Buffer);

Properties

Type Visibility Source Unit Parent
procedure
function
public
Vcl.Controls.pas
Vcl.Controls.hpp
Vcl.Controls TControl

Description

Sets the text of the control.

Call the SetTextBuf method to set the text of the control to the text in the specified buffer.

The text is set to the text in the buffer pointed to by the Buffer parameter. Buffer must point to a null-terminated string. The SetTextBuf method sends the WM_SETTEXT and CM_TEXTCHANGED messages. Doing this in the tight execution of a function can result in the change not being seen until messages from the Windows message queue are processed after the function finishes executing. To interrupt a function's execution and process messages, use the ProcessMessages method of the Application object.

Note: The SetTextBuf method is provided for backwards compatibility only. To set the text of a control now, assign a string value to the Text property.

See Also

Personal tools
In Other Languages
Previous Versions
Assistance