Private Sub DataGridView1_CellMouseDoubleClick(sender As Object, e As DataGridViewCellMouseEventArgs) Handles DataGridView1.CellMouseDoubleClick
With DataGridView1
FrmPayout.txtdocuno.Text = .Rows(e.RowIndex).Cells(1).Value.ToString
End With
Me.Close()
End Sub
public Item As String
Private Sub DataGridView1_CellMouseDoubleClick(sender As Object, e As DataGridViewCellMouseEventArgs) Handles DataGridView1.CellMouseDoubleClick
Item = DataGridView1.Rows(e.RowIndex).Cells(1).Value.ToString
Me.Close()
End Sub
form1 Code (VB.NET)
Dim f as new form2()
f.Showdialog()
Textbox.text = f.Item '