We value your feedback.
Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!
Sub ListTbls() Dim cnn As ADODB.Connection 'Dim myTable As ADODB.Table Set cnn = New ADODB.Connection With cnn .CursorLocation = adUseServer .ConnectionTimeout = 500 .Provider = "Microsoft.ACE.OLEDB.12.0" .ConnectionString = "Data Source=C:\Database.accdb" .Open .CommandTimeout = 500 End With For Each myTable In cnn.Tables If myTable.Type <> "VIEW" And _ myTable.Type <> "SYSTEM TABLE" And _ myTable.Type <> "ACCESS TABLE" Then MsgBox myTable.Name Next myTable Set cnn = Nothing End Sub
Add your voice to the tech community where 5M+ people just like you are talking about what matters.
Join the community of 500,000 technology professionals and ask your questions.