如何使用其他页面gridview中的按钮 [英] how to use a button present in other page's gridview
本文介绍了如何使用其他页面gridview中的按钮的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我在abc.aspx页面的网格视图中有一个图像按钮,当我检查xyz.aspx中的复选框时,我必须使其visble属性为true或false。我将如何做。帮助
I have an image button in grid view of abc.aspx page and i have to make its visble property true or false when i will checked a checkbox present in xyz.aspx. how will i do.help
推荐答案
根据需要在Session,catch,querystring或其他状态模式下存储任何标志,并相应地放置你的逻辑。
storing any flag in Session, catch, querystring or other state mode as per requirement and place your logic accordingly.
// In xyz.aspx page....
string url = "abc.aspx?chkId=" + chk.SelectedItem.Value;
Response.Redirect(url);
// In abc.aspx page....
protected void grv1_RowItemCreated(object sender, GridViewRowEventArgs e)
{
int i = Convert.ToInt32(Request.QueryString["chkId"]);
//Do Something....
}
这篇关于如何使用其他页面gridview中的按钮的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文