unit Unit1;

interface

uses
  Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms,
  Dialogs, StdCtrls;

type
  TForm1 = class(TForm)
    Edit1: TEdit;
    Edit2: TEdit;
    Edit3: TEdit;
    Label1: TLabel;
    procedure Edit1Exit(Sender: TObject);
    procedure Edit1Enter(Sender: TObject);
  private
    { Private declarations }
  public
    { Public declarations }
  end;

var
  Form1: TForm1;

implementation

{$R *.dfm}

procedure TForm1.Edit1Enter(Sender: TObject);
begin
  if Sender is TEdit then
  begin
    Label1.Caption:='Jestem w '+(Sender As TEdit).Name;
    (Sender As TEdit).Color:=clLime;
  end;
end;

procedure TForm1.Edit1Exit(Sender: TObject);
begin
 (Sender As TEdit).Color:=clWhite;
end;

end.
