回车登录---最简代码

来源:互联网 发布:python格式化输出内容 编辑:程序博客网 时间:2024/05/21 12:39

 protected void Page_Load(object sender, EventArgs e) {  //回车登录  

TextBox1.Attributes.Add("onkeypress", "if(event.keyCode==13){document.all.btnEnter.click();return false;}");

 }

原创粉丝点击