For i As Integer = 0 To DGV3.Rows.Count() - 1
Dim AMT As String
AMT = DGV3.Rows(i).Cells(0).Value
If AMT <> "" Then
DGV3.CurrentCell = DGV3.Rows(i).Cells(2)
DGV3.BeginEdit(True)
DGV3.CurrentRow.Cells(2).Value = Me.DGV1.CurrentRow.Cells(0).Value
End If
Next
For i As Integer = 0 To DGV3.Rows.Count() - 1
Dim AMT As String
AMT = DGV3.Rows(i).Cells(1).Value
If AMT <> "" Then
DGV3.CurrentCell = DGV3.Rows(i).Cells(3)
DGV3.BeginEdit(True)
DGV3.CurrentRow.Cells(3).Value = Me.DGV2.CurrentRow.Cells(0).Value
End If
Next
Result
Tag : .NET, Ms SQL Server 2008, Win (Windows App), VB.NET, VS 2015 (.NET 4.x), Windows