Sign in Join

Live chat for Free Pascal, Lazarus, Delphi and every Pascal programmer.

Mailing lists / lazarus / 2009-01

Problem with setting content to TMemo

2 messages · 2 people ·

Reply by email Subscribe to this list Your subscription

Read-only archive. Use j and k to move between messages.

And3mD

Hello
When I try set memo content with Text property I have different results with the same string in different places:
1. In the FormCreate() procedure to the Memo content is added one extra empty line
2. In ButtonClick() procedure there is no problem (no extra empty line added)

Is this a bug or I dont known something?

Example code (Button1Click says No):
http://and3md.xon.pl/lazarus/memotext.zip

procedure TForm1.Button1Click(Sender: TObject);
begin
   if Memo1.Lines.Text=Memo2.Lines.Text then
     ShowMessage('Yes')
   else
     ShowMessage('No');
end;
procedure TForm1.Button3Click(Sender: TObject);
begin
   Memo2.Lines.Text:='lazarus';
end;
procedure TForm1.FormCreate(Sender: TObject);
begin
   Memo1.Lines.Text:='lazarus'
end;

Button1Click says No.
I use Lazarus-0.9.27-18454-fpc-2.2.3-20090127-win32.exe REGARDS

Andrzej And3mD Kilijanski
Vincent Snijders
to And3mD
And3mD wrote 11 lines
Hello When I try set memo content with Text property I have different results with the same string in different places: 1. In the FormCreate() procedure to the Memo content is added one extra empty line 2. In ButtonClick() procedure there is no problem (no extra empty line added) Is this a bug or I dont known something?

Seems like:
http://bugs.freepascal.org/view.php?id=9653

Vincent