Solved

Abort Problem

Posted on 1998-10-19
8
271 Views
Last Modified: 2010-04-06
I have tried useing the BDE declared in my uses section, but why it cause the Abort procedure could not be compile. The
error message is : Statement expected, but expression of
type 'Integer' found. (Delphi 3)
0
Comment
Question by:MikeWang
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
8 Comments
 
LVL 4

Expert Comment

by:dwwang
ID: 1343359
Hi, would you please paste you code fragment?
0
 
LVL 8

Expert Comment

by:ZifNab
ID: 1343360
hi mikewang,

Are you sure you haven't forgotten to write a simple ';'?

Regards, Zif.
0
 
LVL 10

Expert Comment

by:viktornet
ID: 1343361
Hello MikeWang ....

As those guys underlined there is nothing wrong w/ the BDE declaration. You've forgotten to place a "(" or a ";" w/o the quotes... Or something similar to these..

Cheers,
Viktor
0
Independent Software Vendors: We Want Your Opinion

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

 
LVL 12

Expert Comment

by:rwilson032697
ID: 1343362
as dwwang says, the code fragment causing the problem would be useful...
0
 
LVL 10

Expert Comment

by:viktornet
ID: 1343363
Yup B-)

Vik
0
 
LVL 4

Expert Comment

by:BoRiS
ID: 1343364
MikeWang

Yip a code sample would be great, also check this it's the most common problem with this error message...make sure you have all the end; in E.G.

begin
 code.here.....
  if code.here then begin
   some more code...
  end;//make sure you add the end to this statement
end;

Later
BoRiS

0
 
LVL 10

Accepted Solution

by:
Lischke earned 100 total points
ID: 1343365
Hi MikeWang,

I believe the compiler error comes from a double declaration of Abort. You have to write SysUtils.Abort; instead of just Abort;

That's all.

Ciao, Mike
0
 

Author Comment

by:MikeWang
ID: 1343366
Because my Program uses the DBISaveChanges function, so I add
the BDE declared in the uses section, but found it cause
the Abort procedure could not be compile (if a unit not include Abort procedure, the unit could be compile).
The following is a test Program.

unit Unit1;

interface

uses
  Windows, Messages, SysUtils, Classes, Graphics, Controls, Forms, Dialogs, StdCtrls, Bde;
type
  TForm1 = class(TForm)
    Edit1: TEdit;
    Button1: TButton;
    procedure Button1Click(Sender: TObject);
  private
    { Private declarations }
  public
    { Public declarations }
  end;

var
  Form1: TForm1;

implementation

{$R *.DFM}

procedure TForm1.Button1Click(Sender: TObject);
begin
  if Edit1.Text = 'aa' then Abort;
  Color := clGreen;
end;

end.


Regards,
MikeWang



0

Featured Post

Industry Leaders: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Creating an auto free TStringList The TStringList is a basic and frequently used object in Delphi. On many occasions, you may want to create a temporary list, process some items in the list and be done with the list. In such cases, you have to…
Hello everybody This Article will show you how to validate number with TEdit control, What's the TEdit control? TEdit is a standard Windows edit control on a form, it allows to user to write, read and copy/paste single line of text. Usua…
NetCrunch network monitor is a highly extensive platform for network monitoring and alert generation. In this video you'll see a live demo of NetCrunch with most notable features explained in a walk-through manner. You'll also get to know the philos…
Add bar graphs to Access queries using Unicode block characters. Graphs appear on every record in the color you want. Give life to numbers. Hopes this gives you ideas on visualizing your data in new ways ~ Create a calculated field in a query: …

695 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question