Vou explicar.Sei que não fui muito claro a respeito do erro.
unit Unit2;
interface
uses
Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms,
Dialogs, StdCtrls, ComObj, OleCtnrs, ComCtrls, DB, DBTables,StrUtils,
Grids, DBGrids, ExtCtrls;
type
TForm1 = class(TForm)
Button1: TButton;
OpenDialog1: TOpenDialog;
Memo1: TMemo;
Label1: TLabel;
OleContainer1: TOleContainer;
ProgressBar1: TProgressBar;
DataSource1: TDataSource;
Table1: TTable;
procedure Button1Click(Sender: TObject);
private
{ Private declarations }
public
{ Public declarations }
end;
var
Form1: TForm1;
Stv:String;
Md:Boolean;
implementation
begin
{$R *.dfm}
//********************************************************
// JUSTAMENTE AQUI DÁ O ERRO.
//[Error] Unit2.pas(37): Statement expected but ´PROCEDURE´ found
//********************************************************
Procedure VerifyNumericalString;
var
x,xx:integer;
label StringNumOk,StringNumError;
begin
for x:=1 to length(Stv) do
begin
for xx:=48 to 57 do
begin
if Stv[x]=chr(xx) then goto StringNumOk
end;
Stv:=´StringNumError´;
goto StringNumError;
StringNumOk:
end;
StringNumError:
end;
interface
uses
Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms,
Dialogs, StdCtrls, ComObj, OleCtnrs, ComCtrls, DB, DBTables,StrUtils,
Grids, DBGrids, ExtCtrls;
type
TForm1 = class(TForm)
Button1: TButton;
OpenDialog1: TOpenDialog;
Memo1: TMemo;
Label1: TLabel;
OleContainer1: TOleContainer;
ProgressBar1: TProgressBar;
DataSource1: TDataSource;
Table1: TTable;
procedure Button1Click(Sender: TObject);
private
{ Private declarations }
public
{ Public declarations }
end;
var
Form1: TForm1;
Stv:String;
Md:Boolean;
implementation
begin
{$R *.dfm}
//********************************************************
// JUSTAMENTE AQUI DÁ O ERRO.
//[Error] Unit2.pas(37): Statement expected but ´PROCEDURE´ found
//********************************************************
Procedure VerifyNumericalString;
var
x,xx:integer;
label StringNumOk,StringNumError;
begin
for x:=1 to length(Stv) do
begin
for xx:=48 to 57 do
begin
if Stv[x]=chr(xx) then goto StringNumOk
end;
Stv:=´StringNumError´;
goto StringNumError;
StringNumOk:
end;
StringNumError:
end;
Host
Curtidas 0
Respostas
Arc
09/09/2003
Caro colega
me diga o que faz um [b:2a9bca1b61]Begin[/b:2a9bca1b61] debaixo de implementation ???
me diga o que faz um [b:2a9bca1b61]Begin[/b:2a9bca1b61] debaixo de implementation ???
GOSTEI 0
Fred
09/09/2003
unit Unit2;
interface
uses
Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms,
Dialogs, StdCtrls, ComObj, OleCtnrs, ComCtrls, DB, DBTables,StrUtils,
Grids, DBGrids, ExtCtrls;
type
TForm1 = class(TForm)
Button1: TButton;
OpenDialog1: TOpenDialog;
Memo1: TMemo;
Label1: TLabel;
OleContainer1: TOleContainer;
ProgressBar1: TProgressBar;
DataSource1: TDataSource;
Table1: TTable;
procedure Button1Click(Sender: TObject);
private
{ Private declarations }
public
{ Public declarations }
end;
var
Form1: TForm1;
Stv:String;
Md:Boolean;
implementation
begin //TIRA ESSE ´BEGIN´ DAQUI RAPAZ
{$R *.dfm}
//********************************************************
// JUSTAMENTE AQUI DÁ O ERRO.
//[Error] Unit2.pas(37): Statement expected but ´PROCEDURE´ found
//********************************************************
Procedure VerifyNumericalString;
var
x,xx:integer;
label StringNumOk,StringNumError;
begin
for x:=1 to length(Stv) do
begin
for xx:=48 to 57 do
begin
if Stv[x]=chr(xx) then goto StringNumOk
end;
Stv:=´StringNumError´;
goto StringNumError;
StringNumOk:
end;
StringNumError:
end;
interface
uses
Windows, Messages, SysUtils, Variants, Classes, Graphics, Controls, Forms,
Dialogs, StdCtrls, ComObj, OleCtnrs, ComCtrls, DB, DBTables,StrUtils,
Grids, DBGrids, ExtCtrls;
type
TForm1 = class(TForm)
Button1: TButton;
OpenDialog1: TOpenDialog;
Memo1: TMemo;
Label1: TLabel;
OleContainer1: TOleContainer;
ProgressBar1: TProgressBar;
DataSource1: TDataSource;
Table1: TTable;
procedure Button1Click(Sender: TObject);
private
{ Private declarations }
public
{ Public declarations }
end;
var
Form1: TForm1;
Stv:String;
Md:Boolean;
implementation
begin //TIRA ESSE ´BEGIN´ DAQUI RAPAZ
{$R *.dfm}
//********************************************************
// JUSTAMENTE AQUI DÁ O ERRO.
//[Error] Unit2.pas(37): Statement expected but ´PROCEDURE´ found
//********************************************************
Procedure VerifyNumericalString;
var
x,xx:integer;
label StringNumOk,StringNumError;
begin
for x:=1 to length(Stv) do
begin
for xx:=48 to 57 do
begin
if Stv[x]=chr(xx) then goto StringNumOk
end;
Stv:=´StringNumError´;
goto StringNumError;
StringNumOk:
end;
StringNumError:
end;
GOSTEI 0