Articles   Members Online:
-Article/Tip Search
-News Group Search over 21 Million news group articles.
-Delphi/Pascal
-CBuilder/C++
-C#Builder/C#
-JBuilder/Java
-Kylix
Member Area
-Home
-Account Center
-Top 10 NEW!!
-Submit Article/Tip
-Forums Upgraded!!
-My Articles
-Edit Information
-Login/Logout
-Become a Member
-Why sign up!
-Newsletter
-Chat Online!
-Indexes NEW!!
Employment
-Build your resume
-Find a job
-Post a job
-Resume Search
Contacts
-Contacts
-Feedbacks
-Link to us
-Privacy/Disclaimer
Embarcadero
Visit Embarcadero
Embarcadero Community
JEDI
Links
how to list BDE error codes by code Turn on/off line numbers in source code. Switch to Orginial background IDE or DSP color Comment or reply to this aritlce/tip for discussion. Bookmark this article to my favorite article(s). Print this article
BDE error codes by code 02-Nov-02
Category
BDE
Language
Delphi 2.x
Views
172
User Rating
No Votes
# Votes
0
Replies
0
Publisher:
DSP, Administrator
Reference URL:
DKB
			Author: Radikal Q3

Show/generate the BDE errors list.

Answer:

The list of errors of the BDE, we can obtain it investigating a little in the file 
bde.int 
There we will see that the error codes are composed of a value ' base' and of an 
offset. 

Here you have an invention to generate your listing of errors of the BDE: 

Add 'dbiprocs' in the uses of your form 
Put a TRichEdit (RE1) 
And put this in the OnClick of a TButton: 

1   procedure TForm1.Button1Click(Sender: TObject);
2   const 
3     Bases:array [1..24] of integer=(
4       0,$2100,$2200,$2300,$2400,$2500,$2600,$2700,$2800,
5       $2900,$2A00,$2B00,$2C00,$2D00,$2E00,$2F00,$3000,
6       $3100,$3200,$3300,$3400,$3500,$3E00,$3F00);
7   var 
8      ErrorCod:integer;
9      ErrorTexto:array [0..DBIMAXMSGLEN+1] of char;
10     i,n:integer;
11  begin 
12    for i:=1 to 24 do 
13      for n:=0 to 255 do 
14      begin 
15        ErrorCod:=Bases[i]+n;
16        DbiGetErrorString(ErrorCod,ErrorTexto);
17        if ErrorTexto<>'' then 
18          Re1.Lines.Add('$'+IntToHex(ErrorCod,4)+' ('+
19                        IntToStr(ErrorCod)+') = '+ErrorTexto);
20        Application.ProcessMessages;
21      end; 
22  end; 


			
Vote: How useful do you find this Article/Tip?
Bad Excellent
1 2 3 4 5 6 7 8 9 10

 

Advertisement
Share this page
Advertisement
Download from Google

Copyright © Mendozi Enterprises LLC