Click here to Skip to main content
15,885,366 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
I have a html textbox of type text when its shown in page it should be of type password in some cases where as it must act as regular text box.
Posted
Comments
[no name] 17-Jan-13 4:51am    
txtboxID.TextMode="SingleMode"; in code behind for specific condition(as u told)

1 solution

Use the TextMode property to toggle between the different requirements (although my personal opinion is never to have anything with two distinct uses).

Examples and hints on using this can be found at

http://stackoverflow.com/questions/7709243/initialize-textbox-with-the-password-textmode[^]

and

http://ryanfarley.com/blog/archive/2004/12/18/1300.aspx[^]

amongst others
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900