Private Sub DgridKeyDown(sender As System.Object, e As Windows.Forms.KeyEventArgs) Handles dgrid.KeyDown Dim crRowIndex As Integer = dgrid.CurrentCell.RowIndex If crRowIndex + 1 = dgrid.Rows.Count Then Else Dim row As DataGridViewRow = dgrid.SelectedRows(0) Loadcontrolsfromgridview(row) End If End Sub
Private Sub Loadcontrolsfromgridview(row As DataGridViewRow) _primarykey = 0 tbxdescription.Text = row.Cells("Description").Value _primarykey = row.Cells("TitleID").Value btnsave.Text = "Update [F2]" End Sub
Network and collaborate with thousands of CTOs, CISOs, and IT Pros rooting for you and your success.
”The time we save is the biggest benefit of E-E to our team. What could take multiple guys 2 hours or more each to find is accessed in around 15 minutes on Experts Exchange.