Set TextMode property to Password - Create a TextBox for retrieving password from user - ASP.NET

Q.  How do you create a TextBox for retrieving a password from a user?
- Published on 28 Jul 15

a. Set TextMode property of the TextBox control to Secret.
b. Set Mode property of the TextBox control to Password.
c. Set Text property of the TextBox control to Password.
d. Set TextMode property of the TextBox control to Password.

ANSWER: Set TextMode property of the TextBox control to Password.
 

    Discussion

  • Raj   -Posted on 19 Oct 15
    Set TextMode property of the TextBox control to Password to convert normal textbox as password formatted textbox.
    There is mode property of textbox control that has three main values.
    • SingleLine
    • Multiline
    • Password
    SingleLine is default mode of textbox control.

Post your comment / Share knowledge


Enter the code shown above:
 
(Note: If you cannot read the numbers in the above image, reload the page to generate a new one.)