title: How to add auto increment number on my new column VB.NET
body: <p>My Datagridview contains data's from my database and I Added new column but i want to insert auto increment number in this column how to do it.</p>
  
  <p>Here's my code for my newly added column</p>
  
  <pre><code>Private Sub Form1_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
  
      Dim idcolumn As New DataGridViewTextBoxColumn
  
      With idcolumn
          .HeaderText = "ID"
          .Name = "ID"
  
      End With
  
       Dim count as Integer  ="1"
      count = Val(count) +1
      With DataGridView1
          .Columns.Add(idcolumn)
      End With
  </code></pre>
  
  <p>End Sub</p>