Vcl.StdCtrls.TMemo.Lines

From RAD Studio API Documentation
Jump to: navigation, search

Delphi

property Lines: TStrings read FLines write SetLines;

C++

__property Lines;

Properties

Type Visibility Source Unit Parent
property published
Vcl.StdCtrls.pas
Vcl.StdCtrls.hpp
Vcl.StdCtrls TMemo

Description

Contains the individual lines of text in the memo control.

Vcl.StdCtrls.TMemo.Lines inherits from Vcl.StdCtrls.TCustomMemo.Lines. All content below this line refers to Vcl.StdCtrls.TCustomMemo.Lines.

Contains the individual lines of text in the memo control.

Use Lines to manipulate text in an memo control on a line-by-line basis. Lines is a TStrings object, so the TStrings methods may be used for Lines to perform manipulations such as counting the lines of text, adding new lines, deleting lines, or replacing lines with new text. For example:

MyMemo.Lines.Add(...);

To work with all the text at once, use the Text property. To manipulate individual lines of text, the Lines property works better.

Note: Although Lines is implemented as a TStrings descendant, it does not implement the support for associating objects with the strings in the list.

See Also

Code Examples