B
Bob
I'm trying to use the following example code from Access 2000's help system:
Dim obj As AccessObject, dbs As Object
Set dbs = Application.CurrentData
' Search for open AccessObject objects in AllQueries collection.
For Each obj In dbs.AllQueries
If obj.IsLoaded = TRUE then
' Print name of obj.
Debug.Print obj.Name
End If
Next obj
I'm modifying the code to show all queries open or not, so I'm taking out
the isloaded check so it will look somehting like this:
Dim obj As AccessObject, dbs As Object
Set dbs = Application.CurrentData
' Search for open AccessObject objects in AllQueries collection.
For Each obj In dbs.AllQueries
' Print name of obj.
Debug.Print obj.Name
Next obj
Here is the question - I need the listing to be of another Access database
(MDB file), not the "Current" database. Another thing is ... I need to use
ADO not DAO. I have examples of doing it with DAO, but I'd like to use ADO
or this CurrentData method if possible. Thanks!
Dim obj As AccessObject, dbs As Object
Set dbs = Application.CurrentData
' Search for open AccessObject objects in AllQueries collection.
For Each obj In dbs.AllQueries
If obj.IsLoaded = TRUE then
' Print name of obj.
Debug.Print obj.Name
End If
Next obj
I'm modifying the code to show all queries open or not, so I'm taking out
the isloaded check so it will look somehting like this:
Dim obj As AccessObject, dbs As Object
Set dbs = Application.CurrentData
' Search for open AccessObject objects in AllQueries collection.
For Each obj In dbs.AllQueries
' Print name of obj.
Debug.Print obj.Name
Next obj
Here is the question - I need the listing to be of another Access database
(MDB file), not the "Current" database. Another thing is ... I need to use
ADO not DAO. I have examples of doing it with DAO, but I'd like to use ADO
or this CurrentData method if possible. Thanks!