应该是这个样子:select form line_info where combobox1.text & combobox2.text &textbox1.text ,就是SQL
Dim col As String
Dim sql As String
Select Case Combo1.ListIndex
Case 0
col = "carid"
Case 1
col = "name"
Case 3
col = "Ondate"
End Select
sql = "select * from table where " & col & " " & Combo2.Text & " " & text1.Text