Chciałem w konstruktorze obiektu mojej klasyA wpisać do zmiennej vb w klasie jakąś liczbę. Dlaczego występują błędy?
KlasaA = class
private
vb:Integer;
public
procedure ShowMe;
constructor Bar(v:Integer);
end;
var
Form1: TForm1;
watek: TWatek;
oKlasaA: KlasaA;
implementation
{$R *.dfm}
procedure TForm1.Button2Click(Sender: TObject);
begin
oKlasaA := KlasaA.Bar(57);
end;
procedure KlasaA.Bar(v:Integer);
begin
self.vb:=v;
end;
procedure KlasaA.ShowMe;
begin
Form1.Caption:=IntToStr(self.vb);
end;
Declaration Bar differs from previous declaration
Unsatisfied Forward or External declaration KlasaA.Bar