Public Sub FillCountNonDRDOVR(ByVal nrod As Integer, ByVal cevt As String, ByVal ngo As Integer) Dim cmd = New SqlCommand("sp_CountBBNonDRDOVR") cmd.CommandType = CommandType.StoredProcedure cmd.Parameters.Add("@rodeoid", SqlDbType.Int).Value = nrod cmd.Parameters.Add("@eventcd", SqlDbType.Char, 2).Value = cevt cmd.Parameters.Add("@goround", SqlDbType.Int).Value = ngo FillDataTable(cmd) End Sub
I have tried several different iterations of the above code but can not seem to get the correct syntax to put the above code in the following form:
Using cmd using as new SqlCommmand
...
End Using
TIA for any help.