Language: VB.NET
Getting the select row from DataGrid
1: Dim rowIndex As Integer = InvoiceLineItemsDataGridView.Rows.Count - 1 2: Dim row As DataGridViewRow _ 3: = InvoiceLineItemsDataGridView.Rows(rowIndex) 4: Dim cell As DataGridViewCell 5: cell = row.Cells(0) 6: cell.Value = 1 7: invoiceSequence += 1 8: cell = row.Cells(1) 9: cell.Value = invoiceSequence 10: cell = row.Cells(2) 11: cell.Value = AccountNoComboBox.SelectedValue 12: cell = row.Cells(3) 13: cell.Value = AccountNoComboBox.Text 14: cell = row.Cells(4) 15: cell.Value = DescriptionTextBox.Text 16: cell = row.Cells(5) 17: cell.Value = AmountTextBox.Text
Report Abuse
Subscribe
Discuss
What's new
What is it
New Snippet
Recent Snippets
My Snippets
Web Code
Search

