我想在GridView链接按钮上打开一个面板 [英] I want to open a panel on gridview linkbutton

查看:74
本文介绍了我想在GridView链接按钮上打开一个面板的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

亲爱的

我如何拥有一个gridview,如果我单击它,就会有一个链接按钮
然后
在页面中打开一个弹出面板

请知道代码

请帮帮我

我对此感到困惑

谢谢

Dear

How I have a gridview there is a linkbutton if i click that
Then
Open a Popup panel within in the page

please if you know the code

Please help me

I am confused with this

Thank you

推荐答案

尝试一下,

Try this ,

private void dataGridView1_CellContentClick(object sender, DataGridViewCellEventArgs e)
 {
     if (e.ColumnIndex == 0 && e.RowIndex >= 0)
     {
         panel1.Top = dataGridView1.Top + 50;
         panel1.Left = dataGridView1.Left + 50;
         panel1.Visible = true;

     }
     else
         panel1.Visible = false;
 }


使用 Modapopup扩展程序弹出

在链接按钮上单击

Use Modapopup extender to pop up

on linkbutton click

protected void LinkButton1_Click(object sender, EventArgs e)
{
    GridViewRow clickedRow = ((LinkButton) sender).NamingContainer as GridViewRow;
    .
    .
    .
   this.modalpopup.Show();
}


这篇关于我想在GridView链接按钮上打开一个面板的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆