Link to home
Start Free TrialLog in
Avatar of pbsl-it
pbsl-it

asked on

Authenticate windows login password using VBA

I am writing an application using VBA in Excel and would like to have the user enter their windows password in an inputbox and then have the application check the password is correct against their actual windows login password.  Is this possible?
Avatar of Jim Horn
Jim Horn
Flag of United States of America image

(This doesn't answer your question, but...)  Just a thought.. if you're running VBA, wouldn't that imply that the user has successfully passed the Windows password login, if the Windows password is set?
Avatar of junglerover77
junglerover77

Yes, it's possible, but you must use some NETAPIs. So you will need to build an Activex DLL for it before you can use those APIs in VBA.

Here is a sample:
https://www.experts-exchange.com/questions/20430176/StrPtr-Problem.html

Regards,
Jungle
ASKER CERTIFIED SOLUTION
Avatar of nffvrxqgrcfqvvc
nffvrxqgrcfqvvc

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of pbsl-it

ASKER

Thanks for the help.  Using "NetUserChangePassword" will be sufficient for what I need.

Cheers

Barry