Hello John,
Actually this behaviour is good, there is nothing to be fixed. The password
is stored in the text property of the control but is not posted to the client.
Remember that this is a webcontrol, if the password was rendered in html,
the user will see some circles, but looking at the html source the value
would be writen in clear text and this is not secure.
There is no way to avoid this behaviour if you stick to the TextBox control.
You could change to an HtmlControl, maybe an HtmlInputText won't hide the
password, then you will see the circles but take a look at the html source
rendered to the client...
A workaround could be making your own TextBox control and post a default
value to the client (different to the password, like a series of white spaces,
question marks or wathever), that will mean to you that no change was done
on that field by the user.
regards,
-----
Ariel Popovsky
I do something like this:
HttpCookie cookie = Request.Cookies[ "AuthInfo" ];
if( cookie != null )
{
tbUserName.Text = cookie.Values[ "UserName" ];
tbPassword.Text = cookie.Values[ "Password" ];
}
This works except tbPassword is a WebControls.TextBox and it's set to
mode "password". It doesn't display the circles indicating that it's
got a value - even though it does.
Anyone know a way to fix this?
Thanks
John.