Board index » delphi » Password protection of table in database

Password protection of table in database

Hello
I have made a paradoxdatabase in Delphi 4.0, and i want to protect one table
with a password, but when I do this, I get a passworddialog that the user
has to enter
a password every time he starts my program. This password ought to be my
security that
the user never can change the data in this table.
This is not meant to a passworddialog for the users, but as a security for
me.

How can I solve this problem ??

Thank you very much !!

Thomas

 

Re:Password protection of table in database


Hi Thomas,

I have the same problem. A couple of line above you message you can find
more about this problem.
You can suppress the passworddialog by doing the following:
Write your own OnPassword event like

Session.OnPassword := Password;

Password is a procedure like

Procedure TForm1.Password(Sender: TObject; var Continue: Boolean);

But now comes the problem. I did the above things but every time the
OnPassword event is triggerd the application will generate an error message
like : Stack overflow.

So I don't exactly don't how you can write your own evant handler. Maybe the
above examples will help you.

You can find more info about this in Help files, try TSession.OnPassword,
TSession.AddPassword, etc

Peter.

Thomas L?keberg S?rensen <thoma...@stud.ntnu.no> wrote in message
news:80cj3b$guu17@forums.borland.com...

Quote
>Hello
>I have made a paradoxdatabase in Delphi 4.0, and i want to protect one
table
>with a password, but when I do this, I get a passworddialog that the user
>has to enter
>a password every time he starts my program. This password ought to be my
>security that
>the user never can change the data in this table.
>This is not meant to a passworddialog for the users, but as a security for
>me.

>How can I solve this problem ??

>Thank you very much !!

>Thomas

Re:Password protection of table in database


Before you open the table call

Session.AddPassword('ThePassword');

Bill
--
Bill Todd (TeamB)
(TeamB cannot respond to questions received via email)

Other Threads