面试啦 - 提供专业面试问题及答案、面试技巧、助您成功面试!
您的当前位置:首页 > 面试题库 > IT面试题 > .net面试题 > 正文

请编程遍历页面上所有 TextBox 控件并给它赋值为 string.Empty

foreach (System.Windows.Forms.Control control in this.Controls)
{
if (control is System.Windows.Forms.TextBox)
{
System.Windows.Forms.TextBox tb = (System.Windows.Forms.TextBox)control ;
tb.Text = String.Empty ;
}
}
词条:net面试题
上一篇:利达恒信公司.NET笔试题面试题 下一篇:.NET笔试题(20个问题)
与该文相关的文章

温馨提示:如果您对面试网有任何建议,请通过网站联系邮箱向我们反馈,感谢各位的建议与支持!