Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations TouchToneTommy on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Password for a form

Status
Not open for further replies.

mdctsg

MIS
May 26, 2002
102
US
Is there a way to put a password on a command button in order to access a form?

Thanks
Bob
 
1. Add a new form2 with only one command button (else you can hide the controls on form load of main form and show only the main command button.)
2. Add a new form3 with fields User Name, Password and cmdbtn OK,Cancel.
3. Create a button(Save) in New Form3 to save these values in registry. You can encrypt the password if u wish.
You can omit this step if you don't want to provide multiple access to the program. In that case you can provide some default password. and the save button will reset the default password after confirmation od old password.

4. On CLICK of your desired button load the Password Form.
5. On click of OK button of Password form, cross check with the stored password in registry.
then open the desired form if New Form2 is loaded first.or make the fields of the Main form visible (if they are hidden earlier)
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top