Board index » delphi » Database problem

Database problem

Try:

Table1.DatabaseName := ExtractFilePath(Appliction.EXEName);
Table1.TableName := 'Table1.DB';
Table2.DatabaseName := ExtractFilePath(Appliction.EXEName);
Table2.TableName := 'Table2.DB';

Quote
guy bashan wrote:

> Hello,

> I'm writing a little program that will use only two paradox tables. Is
> there anything special that I should do except :

> Table1.TableName := ExtractFilePath(Appliction.EXEName) + 'Table1.DB';
> Table2.TableName := ExtractFilePath(Appliction.EXEName) + 'Table2.DB';
> Table1.Open;
> Table2.Open;

> Is'nt there any additional code that should come somewhere  ? ? ?

> 10x in advance,
> Bashan.

 

Re:Database problem


Hello,

I'm writing a little program that will use only two paradox tables. Is
there anything special that I should do except :

Table1.TableName := ExtractFilePath(Appliction.EXEName) + 'Table1.DB';
Table2.TableName := ExtractFilePath(Appliction.EXEName) + 'Table2.DB';
Table1.Open;
Table2.Open;

Is'nt there any additional code that should come somewhere  ? ? ?

10x in advance,
Bashan.

  bashan1.vcf
< 1K Download

Re:Database problem


Quote
>I'm writing a little program that will use only two paradox tables. Is
>there anything special that I should do except :

>Table1.TableName := ExtractFilePath(Appliction.EXEName) + 'Table1.DB';
>Table2.TableName := ExtractFilePath(Appliction.EXEName) + 'Table2.DB';
>Table1.Open;
>Table2.Open;

>Is'nt there any additional code that should come somewhere  ? ? ?

>10x in advance,
>Bashan.

You shouldn't place the tables in the same dir as the executable (at least
in Delphi 1.x, it led to problems with files growing very large!).

Also, you should use an Alias for your databasename.

Lastly, TableName should only be 'Table1.DB', the rest goes in the
databasename property (the path).

Later
Frank

Other Threads