Ben formun içindeki bir nesyeyi bulup bulduğum nesnenin caption özelliğini değiştmek istiyorum bu işlemi
Kod: Tümünü seç
while not FDset.Eof do
begin
lKodu:=FDset.FieldByName('KODU').AsInteger;
(FindComponent('lbl_s'+IntToStr(lKodu))as TLabel).Caption:=QuotedStr(FDSet.FieldByName('ADI').AsString);
FDset.Next;
end;
Kod: Tümünü seç
(FindComponent('lbl_s'+IntToStr(lKodu))as TLabel).Caption:=QuotedStr(FDSet.FieldByName('ADI').AsString);
Kod: Tümünü seç
QuotedStr(FDSet.FieldByName('ADI').AsString); Yerine 'Deneme ' bile yazsam sonuç aynı.
Not: Amacıma Case of ile ulaşabiliyorum ancak çok sayıda label olduğu için işlemi kısaltmak istiyorum.