This is a part of my listing program :

// I declare daya and ai as a global variable.

procedure TForm1.FormCreate(Sender: TObject);

begin

daya := 10;

ai := 0.5;

end;

procedure TForm1.Timer2Timer(Sender: TObject);

begin

Shape2.Left := Min(Shape2.Left+1, Image3.Left+22);

if Shape2.Left >= 192 then

begin

a0 := (Shape2.Left-192) DIV 15;

b0 := (Shape2.Left-192) / 15;

c0 := b0-a0;

daya := daya + (ai/15);

if CompareValue(0, c0) = EqualsValue then

g0 := 1

else g0 := 0;

if g0 = 1 then

begin

Chart1.Series[0].Add(daya,inttostr(a0));

Form2.Chart1.Series[0].Add(daya,inttostr(a0));

end

else Chart1.Series[0].Add(daya,' ');

end;

end;

And what I have is an error like the file I attach.

Similar questions and discussions