ASP.NET页面回发后保留密码
protected void Page_Load(object sender, EventArgs e)
{
if (IsPostBack)
{
if (!(String.IsNullOrEmpty(txtPassword.Text.Trim())))
{
txtPassword.Attributes["value"] = txtPassword.Text;
}
}
}