paulthepaddy
Well-known member
Hey Guys I Was Wondering If Any1 Could Help me.
I Want To Show This Data In A ListBox but all i am getting is a blank listbox and no errors
any help will be much appreicated
I Want To Show This Data In A ListBox but all i am getting is a blank listbox and no errors
VB.NET:
Public Sub RecentWork_Display()
Dim connection As New OleDb.OleDbConnection
connection.ConnectionString = ("Provider=Microsoft.ACE.OLEDB.12.0;Data Source=|DataDirectory|\DB.accdb;Persist Security Info=True")
connection.Open()
Dim command As New OleDb.OleDbCommand("SELECT * FROM RecentWork", connection)
With ListBox_Un
.DataSource = command.ExecuteNonQuery
.DisplayMember = "InvoiceName"
End With
'ListBox_Un.DataSource = command.ExecuteNonQuery
connection.Close()
connection.Dispose()
End Sub
any help will be much appreicated