如何通过任何按钮控件从转发器控件获取行详细信息 [英] How to take row details from repeater control by any button control
本文介绍了如何通过任何按钮控件从转发器控件获取行详细信息的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我已经拿了一个按钮,我已经创建了一个事件行命令。我必须选择行详细信息如何可以帮助任何人
我尝试了什么:
[删除重复文本]
i have taken one button and i have crated a event row command.i have to pick the row details how its possible can any one help
What I have tried:
[removed duplicate text]
推荐答案
使用下面的代码获取和处理转发器控件中的控件值的代码段
Use below code snippet to get and process the control values inside your repeater control
protected void Repeater1_ItemDataBound(object sender, RepeaterItemEventArgs e)
{
//Iterate through items in repeater control
foreach (RepeaterItem ri in Repeater1.Items)
{
//fetth the control in repeater item row
YOUR_CONTROL_TYPE ctrl = ri.FindControl("<YOUR_CONTROL>") as YOUR_CONTROL_TYPE;
//put your logic to process the ctrl value here
}
}
这篇关于如何通过任何按钮控件从转发器控件获取行详细信息的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文