110,561
社区成员
发帖
与我相关
我的任务
分享
<input type="text" id="content_1" />
<input type="text" id="content_2" />
<input type="text" id="content_3" />
<input type="text" id="content_4" />
<input type="text" id="content_5" />
上面的哪个表单正在聚焦状态?
var act = document.activeElement.id;
alert(act);
TextBox tx = this.ActiveControl as TextBox;
if (tx == null) //不是可输入控件
return;