Home > Archive > ASP .NET > September 2004 > Password Fields
You are viewing an archived Text-only version of the thread.
To view this thread in it's original format and/or if you want to reply to
this thread please [click here]
|
|
|
| Does any one know how to put text into a password field.
| |
| Jeti [work] 2004-09-30, 11:37 am |
| > Does any one know how to put text into a password field.
Same as any other text field.... < ... value="hello world" ... >
| |
|
| > Same as any other text field.... < ... value="hello world" ... >
I've got it sussed now, thanks.
You idea did not work, although the text property is set, it does not
display it. Its neccessary to set the text property, and use
txtBox.Attributes.Add("Value",someString)
With both set it displays the asterisks and stores the Text value.
| |
| Shiva 2004-09-30, 11:37 am |
| Setting the Text property of the password-mode text box may not work. You
have to use the Attributes collection of the textbox.
txtPwd.Text = "mypwd"; // This will not pre-populate the password field
txtPwd.Attributes.Add ("VALUE", "mypwd"); // but this will...
However, sending a default password is not recommended.
HTH
"Josh" <someone@microsoft.com> wrote in message
news:OVD$hDtpEHA.1160@tk2msftngp13.phx.gbl...
Does any one know how to put text into a password field.
|
|
|
|
|