Create beautiful Images of your Code
Tuesday, 4 May 2021
To check if the procedure already exists and drop
IF EXISTS (SELECT * FROM sys.objects WHERE type = 'P' AND name = 'ProcedureName')
DROP PROCEDURE ProcedureName
GO
Friday, 7 June 2019
To set auto increment id in datagridview
Private Sub DataGridView1_RowPrePaint(ByVal sender As System.Object, ByVal e As System.Windows.Forms.DataGridViewRowPrePaintEventArgs) Handles DataGridView1.RowPrePaint
If e.RowIndex >= 0 Then
Me.DataGridView1.Rows(e.RowIndex).Cells(0).Value = e.RowIndex + 1
End If
End Sub
If e.RowIndex >= 0 Then
Me.DataGridView1.Rows(e.RowIndex).Cells(0).Value = e.RowIndex + 1
End If
End Sub
Thursday, 2 May 2019
Subscribe to:
Posts (Atom)