1. are you sure the id is correct? show your ItemTemplate?ListItemType itemType = e.Item.ItemType;
if (itemType == ListItemType.Item || itemType == ListItemType.AlternatingItem)
{
LinkButton btn=(LinkButton)e.Item.FindControl("btn");
if (btn != null)
btn.Text="dddddddddddddddd";
}2. if you set the Visible = false, the control is never output to the client side, and it will not have a value when the postback occurs
if (itemType == ListItemType.Item || itemType == ListItemType.AlternatingItem)
{
LinkButton btn=(LinkButton)e.Item.FindControl("btn");
if (btn != null)
btn.Text="dddddddddddddddd";
}2. if you set the Visible = false, the control is never output to the client side, and it will not have a value when the postback occurs
解决方案 »
- 关于TreeView的问题。
- Repeater 的 OnItemCommand 用法,出问题了 求解 啊...
- js 刷新 updatePanel
- 老web程序 要改成PDA 掌上电脑可以正常访问
- 通过传递文件路径来上传文件。。。出问题了。。。。。。
- 版本的问题
- [ORACLE问题] 我在存储过程里用了 pioContent IN OUT CLOB,但是读不出值来怎么办?
- 我为什么进不去搜狐网站!是什么原因呀!
- 怎么样在dataset里的一张表里作筛选,将结果存进另一张表里,或者与一个datagrid绑定,紧急求助,真的是很急
- 请教有关字体颜色的问题??
- ???各位高手●讨论●:网页间传递参数的好的方法(不能让用户看见)???
- 我要用repeater控件的OnItemCommand事件
我的ItemTemplate标签里面是这样
<asp:linkbutton id="btn" runat="server" EnableViewState="False" CausesValidation="False" BackColor="Transparent" CommandArgument="<%#省略,是绑定数据%>" CommandName="modbtn">修改</asp:linkbutton>2。我要修改一条记录,要用到一个隐藏的控件记录这条记录的id值呀,还有什么好办法吗?
第二个怎么办呢,我用html控件好用,如果用服务器控件或者别的办法怎么做比较好点呢