Code:
procedure TForm1.Button1Click(Sender: TObject);
var Komponenta:TComponent;
begin
Komponenta := FindComponent(Edit1.Text);
with TPanel(Komponenta) do
Color := clBlue;
end;
//Ako je u pitanju Edit, onda zameniti TPanel sa TEdit
Samo pazi, ako ne postoji komponenta sa imenom npr. "Panel1", doci ce do greske tipa "Access violation at xxxblablaxxx".
A man is smart. People are stupid.
My blog