Results 1 to 3 of 3

Thread: [2005] rows in datagridview

  1. #1

    Thread Starter
    Fanatic Member
    Join Date
    Aug 2006
    Posts
    734

    Cool [2005] rows in datagridview

    Hi guys,
    I need to go through every row in my datagridview ignoring the first row each time.
    Now i have the code
    VB Code:
    1. For each row as DataGridViewRows in DataGridView1.Rows
    2. 'do whatever i need to
    3. Next
    But i need to tweek it slightly so that the first row is ignored.
    Any ideas anybody?
    Thanks in advance

  2. #2
    Member
    Join Date
    Jan 2006
    Posts
    53

    Re: [2005] rows in datagridview

    How about:

    VB Code:
    1. For i As Integer = 1 to DataGridView1.Rows.Count - 1
    2.     Dim row as DataGridViewRows = DataGridView1.Rows(i)
    3.     'do whatever i need to
    4. Next

  3. #3

    Thread Starter
    Fanatic Member
    Join Date
    Aug 2006
    Posts
    734

    Re: [2005] rows in datagridview

    Yep, works fine. Thanx.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width