摘要:
//遍历ID为Panel1的panel里的所有label控件 foreach (Control ctl in this.Panel1.Controls) { //判断类型为Label的 if (ctl.GetType() == typeof(Label)) { //排除不需要的label if (c 阅读全文
摘要:
后台代码: lb1.Attributes.Add("onclick", "getSN('" + lb1.Text.Trim() + "')"); lb1是前端label的ID,getSN是放在前端js中点击label后所执行的方法; 前端这样写: <script type="text/javascr 阅读全文