Link to home
Start Free TrialLog in
Avatar of srikanthv2322
srikanthv2322

asked on

Password Mask in INPUT BOX for VBA

I need the characters entered in the InputBox to be Password masked,

Example:
Dim Password
Password = InputBox("Enter Your Password:")

When the user enters password, it should be masked with * symbol
Avatar of jppinto
jppinto
Flag of Portugal image

The inputbox does not accept a mask, for that you will need to make an input form with a masked textbox.

jppinto
SOLUTION
Avatar of jppinto
jppinto
Flag of Portugal image

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
ASKER CERTIFIED SOLUTION
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
If I am not wrong then you can achieve what you want...

Let me create an example for you...

Sid
SOLUTION
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
SOLUTION
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 Rory Archibald
FWIW, the above code ought to be attributed to Daniel Klann, I believe.
I always wondered who wrote that code. Could never find it out. Have been using it for couple of years now...

Thanks for the info. Is he a MVP, Rory?

Sid
Not that I am aware of, though he may have been. His site seems to have disappeared.
No wonder I could never find out. Thanks Rory.

Sid
@srikanthv2322: Could you please explain your Choice of answer?

Sid
The code that I gave above does what you want. Please check the sample that I have attached.

Sid
I'm curious too.  How can "confirm can't be done" be an answer, when a solution was provided...

Perhaps the wrong answer was checked???

Cheers,

dave
srikanthv2322,

Please explain your choice of 'Accepted' answer as it does not provide a solution to your question. In fact it even says it cannot be achieved with an InputBox and gives a link to an MS site which confirms it cannot be done that way.

Patrick
modus_operandi: There were 3 solutions provided in this thread. By me, Patrick and David.

Sid
Avatar of zmau
zmau

Are these points or dollars ?