当前位置: 代码迷 >> ASP.NET >> findcontrol使用求救解决办法
  详细解决方案

findcontrol使用求救解决办法

热度:9964   发布时间:2013-02-25 00:00:00.0
findcontrol使用求救
请问在ASP.NET中,我用以下一行代码获得datalist控件中edititemtemplate模板中文本框里的内容时,得到的是文本框里没有修改前的内容。
      dim   newxm   as   string=ctype(e.item.findcontrol( "xx_xm "),textbox).text


------解决方案--------------------------------------------------------
是否判断回传?
protected void Page_Load(object sender, EventArgs e)
{
if (!Page.IsPostBack)
{
//绑定数据
}
}
  相关解决方案