Próbuję skompilować ten kod
unit Unit1;
{$mode objfpc}{$H+}
interface
uses
Classes, SysUtils, FileUtil, Forms, Controls, Graphics, Dialogs, ExtCtrls,
LazHelpHTML, Buttons, Grids, MaskEdit, CheckLst, StdCtrls, Dos;
type
{ TForm1 }
TForm1 = class(TForm)
Update_1: TBitBtn;
Update_2: TBitBtn;
Update_3: TBitBtn;
Update_4: TBitBtn;
Microsoft_Framework_3_5_1: TStaticText;
Microsoft_Framework_4_5: TStaticText;
Microsoft_Framework_4_6: TStaticText;
Windows_Update: TStaticText;
procedure Update_1Click(Sender: TObject);
procedure ControlBar1Click(Sender: TObject);
procedure MaskEdit1Change(Sender: TObject);
procedure Update_2Click(Sender: TObject);
private
{ private declarations }
public
{ public declarations }
end;
var
Form1: TForm1;
implementation
{$R *.lfm}
{ TForm1 }
procedure TForm1.ControlBar1Click(Sender: TObject);
begin
end;
procedure TForm1.Update_1Click(Sender: TObject);
begin
exec('cmd','')
end;
procedure TForm1.Update_2Click(Sender: TObject);
begin
exec('cmd','')
end;
procedure TForm1.Update_3Click(Sender: TObject);
begin
exec('cmd','')
end;
procedure TForm1.MaskEdit1Change(Sender: TObject);
begin
end;
end.
Otrzymuję bład Compile
Project, Target: project1.exe: Exit code 1, Errors: 1
unit1.pas(58,18) Error: method identifier expected