ive got command below to query db for result = false.I want the switch names returned to be displayed in a textbox. the PROBLEM is only the first result is being returned. I think this is because ive chosen execute scalar but none of the other options seem to work.
Code:Using con2 As New OleDb.OleDbConnection("Provider=Microsoft.Jet.OLEDB.4.0;Data Source=H:\Network Map.mdb") Using command As New OleDb.OleDbCommand("SELECT SwitchName FROM tblSwitch where Result = false", con2) con2.Open() Dim faileddevices As String = CStr(command.ExecuteScalar) RichTextBox5.Text = faileddevices con2.Close() End Using End Using




Reply With Quote