FindControl(TextBox1)然后需要将它强制转化为TextBox 也就是(TextBox)最后取值
解决方案 »
- 如何访问正在被使用的文件?
- Grindview更新失败的问题
- 准备用asp.net做个工单系统,大家有没有演示实例介绍一下?
- 求回收站的算法和SQL……在线等
- AJAX工具添加以后JS失效请高手指点,急!
- [真心求教]三层结构高人速来PK
- 请问一个图片显示的问题. thx
- 如何让TreeView单击某节点后自动收起先前的节点,急啊!!!有高分,拜托!
- ==========急急急急急急,很少遇到的怪问题,本地调试好的,上传到服务器就有问题???
- crystalreport 达人请进来帮小弟解决一个小问题
- datagrid内置分页功能后,string str =Convert.ToString(DataGrid1.DataKeys[e.Item.ItemIndex]);为什么获取不出数据?提示“索引超出范围
- 我想将以下数值以3位分隔显示,怎么办?
是这样的代码么?总是说找不到控件呀?
System.Web.UI.WebControls.RepeaterItemEventArgs e)
{
RepeaterItem item = e.Item;
if( (item.ItemType == ListItemType.Item) ||
(item.ItemType == ListItemType.AlternatingItem) )
{
TextBox tx=new TextBox();
tx = (TextBox) item.FindControl("TextBox1");
string str1=tx.Text;
}
}
System.Web.UI.WebControls.RepeaterItemEventArgs e)
{
RepeaterItem item = e.Item;
if( (item.ItemType == ListItemType.Item) ||
(item.ItemType == ListItemType.AlternatingItem) )
{
((TextBox) item.FindControl("TextBox1")).Text="设置值";
}
}