Sorunum şu: Kendi procedure'umu kendim belirlediğim bir döngüm var. Şu kodlar yardımıyla her seferinde bir sonraki veya bir önceki komponentleri seçtirip bir döngüyü bununla çalıştırabiliyorum. Fakat bu procedureda galiba bir sorun var
Kod: Tümünü seç
Procedure gdongu(sira:string);
var
p:integer;
begin
if sira='siradaki' then
begin
p:=((p+1)mod 21);
FiltreUbox:= TCheckBox(Form6.FindComponent('U' + inttostr(p)));
FiltreBbox:= TCheckBox(Form6.FindComponent('B' + inttostr(p)));
FiltreVbox:= TCheckBox(Form6.FindComponent('V' + inttostr(p)));
FiltreRbox:= TCheckBox(Form6.FindComponent('R' + inttostr(p)));
Yildizbox := TCombobox(Form6.FindComponent('yildiz' + inttostr(p)));
Pozbox := TEdit(Form6.FindComponent('Poz' + inttostr(p)));
end;
if sira='önceki' then
begin
p:=((p-1)mod 21);
FiltreUbox:= TCheckBox(Form6.FindComponent('U' + inttostr(p)));
FiltreBbox:= TCheckBox(Form6.FindComponent('B' + inttostr(p)));
FiltreVbox:= TCheckBox(Form6.FindComponent('V' + inttostr(p)));
FiltreRbox:= TCheckBox(Form6.FindComponent('R' + inttostr(p)));
Yildizbox := TCombobox(Form6.FindComponent('yildiz' + inttostr(p)));
Pozbox := TEdit(Form6.FindComponent('Poz' + inttostr(p)));
end;
end;
Not: Bu yazdığım procedure'u forumlarda araştırıp ordan burdan karıştırarak yazdım belki bu sebepten yanlış olabilir diye tahmin ediyorum