Creating a password-protected program

Thankyou for taking your time to read this question. What I really want to know is how to create a program that onActivate it will prompt you for a passord!

I have tried and tried to get it to work but the script in Delphi 3 keeps on displaying error messages!

Please could you show me in detail how to create a program like that! In detail and correct script please!

This is worth 100 points!

In Delphi format please........
Who is Participating?
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

You can use the new component from rxlib ( version 2.75). TPasswordDialog.
or create a Login form that you call her alone !!! in the dpr :
frmLogin := TfrmLogin;
if frmLogin.ShowModal = mrOk and
   then security := frmLogin.Security;

if security =0 then

Application.FormCreate( frmMain);


Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
hi kinsale,

maybe this helps

modify your Project sourcecode as follows

program pw_app;

  pw_main_u in 'pw_main_u.pas' {Form1},
  pwf_u in 'pwf_u.pas' {PWF};  //PasswordForm not autocreated

{$R *.RES}


  PWF := TPWF.Create(Application);
  If PWF.Edit1.Text = PW then
    PWF.Release;  //Release
    Application.CreateForm(TForm1, Form1);
  else PWF.Release;  //Release

yeah i know what you mean, delphi runs to forms at the same time resulting in a memory error address, yeah i got plenty of them problems. The only other problem a little password box like that is situated on another form, so then because of this your actuall program can still be accessed regardless of if you form is up with showmodal.

take a look at my protect program and if you see something you like in it, you can have the source to it.

The fisrt program you see is protect, another program is mouse.exe this will be your worst nightmare, this unlocks forms using the handle of that window and an api called... enablewindow();  if you find a secure way of a password box please let me know (anyone)

Craig C.
men xinCEOCommented:
I agree with kretzschmar.
You can create your own PassWordInput form to accept user's input.
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today

From novice to tech pro — start learning today.