title: DataGridView Show Selected Row Data In Another Form
body: <p>I have two forms. i already have some values has been displayed in datagridview in one form which is connected to a ms access database. When i click a row from the datagridview in the first from a second form would a appear on the screen and display the data in text boxes. i have Tried the following code below without any success. can someone please help. Thanks</p>
  
  <p>Public Class Main_Frm</p>
  
  <pre><code>Private Sub TBL_TEAMSBindingNavigatorSaveItem_Click(sender As Object, e As EventArgs) Handles TBL_TEAMSBindingNavigatorSaveItem.Click
      Me.Validate()
      Me.TBL_TEAMSBindingSource.EndEdit()
      Me.TableAdapterManager.UpdateAll(Me.FootBallDataSet)
  
  End Sub
  
  Private Sub Main_Frm_Load(sender As Object, e As EventArgs) Handles MyBase.Load
  
      'TODO: This line of code loads data into the 'FootBallDataSet.TBL_TEAMS' table. You can move, or remove it, as needed.
      Me.TBL_TEAMSTableAdapter.Fill(Me.FootBallDataSet.TBL_TEAMS)
  
  End Sub
  
  Private Sub TBL_TEAMSDataGridView_Click(sender As Object, e As EventArgs) Handles TBL_TEAMSDataGridView.Click
  
      If TBL_TEAMSDataGridView.SelectedRows.Count Then
          Dim Schedule_Form As New Schedule_Frm
          Schedule_Form.SelectRows = TBL_TEAMSDataGridView.SelectedRows
          Schedule_Form.ShowDialog()
      End If
  
  End Sub
  </code></pre>
  
  <p>End Class</p>