Hello, Cab I ask some help for my project?
I'm using datagridview to add, edit and search items in ms access table. I already fixed the search button to work and it displays the selected row when I enter the ID value on textbox. My problem now is how will I be able to edit or delete the selected row result directly from datagridview?

Below is the code I'm using in searching row [search button]

Private Sub Button10_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button10.Click
        DataGridView2.DataSource = Me.DataSet4.members.Select("ID=" & TextBox3.Text)
    End Sub

Recommended Answers

All 5 Replies

Anybody home?

DataGridView.Rows.Remove() just supply the necessary parameter.

Also check the properties of the gridview.

Thank you, but I already solve it before I read and my problem was solved by adding DataGridView2.CurrentCell = DataGridView2.Item(0, intcount) below the DataGridView2.Rows(intcount).Selected = True

I thought this forum is not active anymore so I ask a help from other forum. Anyway thanx again :)

Can you share the coding that has been solved. I have the same problem

Can you share the coding that has been solved. I have same problem

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.