|
-
Apr 5th, 2000, 11:40 PM
#1
Thread Starter
Junior Member
OK Gurus, I need some help with this one.
First of all, I am creating an application in Access 97, which means the VBA I am using is from VB 5.0 (I think!)
The security on the database is user-level, meaning every user belongs to a group and has a login ID and password.
Within my app is an admin form so that users can change their passwords and admins can add users, reset users' passwords to a default value, etc. It is meant to be a trimmed down version of Access' own "User and Group Accounts" form (Tools -> Security -> ...), but without the groups part (the admins will not be able to add or remove groups).
On the admin form is a "Reset Password" button (similar to the "Clear Password" button in Access), with which admins will be able to (doh!!!) reset users' passwords. Unfortunately, the User object's "NewPassword" method (as in DBEngine(0).Groups("Users").Users("Joe").NewPassword) requires the user's old password as it's first agrument. Also, the User object's Password property is write-only; it does not return a value and it can only be used when creating a new user! As a result, it appears that an admin cannot reset a user's password without knowing the old password, which kind-of defeats the purpose of an single-click "Reset Password" button!!
I thought of writing a function that would simply delete and recreate the user (thereby getting access to the Password property), but this is inefficient because then the function would also have to re-add that user to any groups he or she may have belonged to, and his permissions, if any, would need to be reset for each and every object (table, form, macro, etc.) within the application. Also, with this method the admin would not be able to reset his own password without going trough the user-level "change password" form' (Access won't permit a logged-in user to delete his own account).
Any help here would be greatly appreciated!
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|