Need to select Gridview Row Column using Winforms

Hello

I am New to c# winforms. I have a gridview control on a winform in c#. It is populated and when I click my button I want to get the value at a specific row and column.

How DO I do that?

      DataSet ds = new DataSet();
      ds = ws.getUserList(a);  //  method returns data set
      GridView1.DataSource = ds.Tables[0];

then in my on_click

    private void btnEdit_Click(object sender, EventArgs e)
    {
         Here get value of colum in selected row
    }

Thanks

Charles BaldoSoftware DeveloperAsked:
Who is Participating?
 
Anurag ThakurTechnical ManagerCommented:
0
 
Charles BaldoSoftware DeveloperAuthor Commented:
No I saw that post. It is for a web froms gridview control. There is no selectedrow property in the winforms version
0
 
Charles BaldoSoftware DeveloperAuthor Commented:
Was able to figure it out from that link
0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.