Search This Blog

Friday, March 19, 2010

Changing Form Caption [Delphi]

This is some small code for those wanting to learn Delphi. This simply changes the text of the caption to whatever the user inputs.

Create a new VCL

Adding 1 button and 1 edit(txtCaption)
Add this simple text and its that easy.


Form1.Caption := txtCaption.Text

This goes in


procedure TForm1.Button1Click(Sender: TObject);
begin
Form1.Caption := txtCaption.Text
end;

No comments:

Post a Comment