procedure SetTextToEditByName(EditName, NewText: String); var e: TEdit; begin e := FindComponent(EditName); if e <> nil then e.Text := NewText; end;