An expression of non-boolean type specified in a context where a condition is expected, near 'List'
0
votes
0
answers
801
views
myconn.Open()
Dim command As New SqlCommand("Select * from Food where Food List = @list", myconn)
command.Parameters.Add("@list", SqlDbType.VarChar).Value = txtbox1.Text
Dim adapter As New SqlDataAdapter(command)
Dim table As New DataTable()
adapter.Fill(table)
the error i get will show at the adapter.fill(table) saying i have non boolean type at(Food List) how do i fix this any idea?beginner at vb
Asked by hunter
(1 rep)
Apr 14, 2020, 01:00 PM