Board index » delphi » BDE 4.51 and Dbase Tables ; create table

BDE 4.51 and Dbase Tables ; create table

I used BDE 4.00 which create dBase IV tables. These tables can be read with
Excel or Word.
Since I use BDE 4.51, the tables are created with Visual Dbase 7.0 format.
These tables can't be read with Excel or Word nor with database module.

Is it possible to create dBase III or dBase IV tables in a Delphi program
with BDE 4.51 ?

Thanks you

Jean-Yves DELOINCE (french man who speak a very poor english)

 

Re:BDE 4.51 and Dbase Tables ; create table


Quote

>Is it possible to create dBase III or dBase IV tables in a Delphi program
>with BDE 4.51 ?

Here is a note I have on how to do it with Create table.
The other way would be to use DbiCreateTable.  You can find an example in
BDE32.hlp

To control the level of a table created using the Delphi TTable.CreateTable
method and use a specific table level (overriding the BDE table level
setting), the TTable.TableLevel property is provided. If the table
definition (features used) falls within this specified table level (or a
lower level), the value specified in the TTable.TableLevel property is the
level of table actually created. If requested features exceed the table
level specified, a level high enough to accommodate the higher level
features is used. No error or warning message is issued if the table
created is of a higher level than specified in the TTable.TableLevel
property.

However, there is currently an error in how the TTable.TableLevel property
is implemented in the DBTables unit. Development is being made aware of
this error. Support is going to try to make a replacement file available on
their Web page. If you have the VCL source code, you can correct the error
in DBTables.pas yourself. In the procedure TTable.CreateTable, the line...

  LvlFldDesc.iLen := StrLen(Level);

...should be changed to:

  LvlFldDesc.iLen := StrLen(Level) + 1;

Add the DBTables unit to the project (not just open the file), select
Project|Build All, and the TTable.TableLevel property will function as it
was designed to.

--
Brian Bushay (TeamB)
Bbus...@DataGuidance.com

Re:BDE 4.51 and Dbase Tables ; create table


Brian Bushay TeamB a crit dans le message
<357fceed.15802...@forums.borland.com>...

Quote
>>Is it possible to create dBase III or dBase IV tables in a Delphi program
>>with BDE 4.51 ?

>Here is a note I have on how to do it with Create table.
>The other way would be to use DbiCreateTable.  You can find an example in
>BDE32.hlp

Thanks a lot of response but it doesn't work properly. My TableLevel is set
to 3 in my program and when I look for Table's level, it's write visual
dBase 7 and I can't read my table with Excel. I assume it's because i use
BDE 4.51.

Jean-Yves DELOINCE

Re:BDE 4.51 and Dbase Tables ; create table


Quote

>Thanks a lot of response but it doesn't work properly. My TableLevel is set
>to 3 in my program and when I look for Table's level, it's write visual
>dBase 7 and I can't read my table with Excel. I assume it's because i use
>BDE 4.51.

Did you modify  DBTables before creating the dbase table you are trying to use?

--
Brian Bushay (TeamB)
Bbus...@DataGuidance.com

Re:BDE 4.51 and Dbase Tables ; create table


Brian Bushay TeamB a crit dans le message
<35783f70.15043...@forums.borland.com>...

Quote

>>Thanks a lot of response but it doesn't work properly. My TableLevel is
set
>>to 3 in my program and when I look for Table's level, it's write visual
>>dBase 7 and I can't read my table with Excel. I assume it's because i use
>>BDE 4.51.

>Did you modify  DBTables before creating the dbase table you are trying to

use?

Of course, I did.
your message was really Ok. I could not compile before. Now, my program
compile but create dBase 7 Table.

Jean-Yves DELOINCE

Other Threads