[Webinar] Streamline your web hosting managementRegister Today

x
  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 243
  • Last Modified:

Change datagridview row number from 0 to 1

Software vb.net & sql server 2005

I am looking for sample code to change datagridview row number to 1 if 0 in the useraddedrow event

Thanks!
0
dave_sky
Asked:
dave_sky
  • 3
  • 2
1 Solution
 
Jorge PaulinoIT Pro/DeveloperCommented:
0
 
dave_skyAuthor Commented:
That example will not work
0
 
Jorge PaulinoIT Pro/DeveloperCommented:
why?
0
 
dave_skyAuthor Commented:
This is what I tried...

Private Sub TblBasicUpgradesDetailDataGridView_DefaultValuesNeeded(ByVal sender As Object, _
        ByVal e As System.Windows.Forms.DataGridViewRowEventArgs) _
        Handles TblBasicUpgradesDetailDataGridView.DefaultValuesNeeded

        With e.Row
            .Cells("sysAppOrder").Value = "1"
           
        End With

    End Sub
0
 
dave_skyAuthor Commented:
Thanks! It worked after all...
0

Featured Post

Free Tool: Site Down Detector

Helpful to verify reports of your own downtime, or to double check a downed website you are trying to access.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

  • 3
  • 2
Tackle projects and never again get stuck behind a technical roadblock.
Join Now