??Delphi 2.0 and DBase-III database under NT
Hy,
a problem and no clue again ... %-((
I am trying to write a simple app that would append a record do a DBase
database. When I run it on my Win95 machine, the stuff runs great, when
I try to run it under Win NT3.51 Server, I get an error message that the
database cannot be opened.
Trials:
1. win95 machine running prog. on local disk OK
2. win95 machine running prog. on server's local disk OK
3. winNT machine logged as same user as in 1. on local disk FAIL
4. winNT machine logged as admin on local disk FAIL
so I do not think that problem is user rights or something, I rather
think that the problem is actually the Delphi 2.0 program running under
NT.
Any suggestions ?
Andrej
PS:
basics of program:
{ I open F-Textfile for debug purposes only, works OK }
uses
SysUtils, Windows, Messages, Classes, Graphics, Controls,
Forms, DBTables;
var
cFileName: String;
Data: TTable;
begin { SprejmiOceno }
cFileName := 'test.DBF';
if not FileExists(cFileName) then
writeln(F,'No such file')
else {FileExists }
begin
writeln(F,'begin append');
Data := TTable.Create(Application);
writeln(F,'pointer created');
Data.TableName := cFileName;
try { Data.Open }
Data.Open;
writeln(F,' database opened '); { this doesnt run anymore }
Data.Insert;
writeln(F,'record inserted ');
Data.FieldByName('date').AsString := DateToStr(Date);
Data.Post;
Data.Close;
Data.Destroy;
except { Data.Open }
on EDataBaseError do
writeln(F,'Cannot open');
end; {try Data.Open }
end; { else FileExists }
end; { SprejmiOceno }