How to design a password textbox?

S

Samuel

An example program gave me a demo how to design a keypad (button
matrix) and append entered key to a string, but show "*" (star) signs
in a text box.


The Programmer-designed screen keypad works. My question is: How to
design that if user key in from keyboard, instead from the
programmer-designed screen keypad? I tried key_up, key_press, ...
events. All of these, anybody will see the characters user typed in. It

doesn't look like the popular method when we want to login a computer.
 
J

James Thresher

Hi,

You will need to set the PasswordChar property of the text box to the
character you want to appear i.e. '*', then whenever a value is
entered into the text box either from a user typing or its .Text
property being set the text box will only display '*' characters.

Regards

James Thresher
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top