M
Margaret Bartley
I'm opening a remote Access database and reading each module in it. This
works. What I'd like to do now is open each module to get at the module
properties.
The following code snippet works to list the modules in a connected
database:
Set cntModule = LookupDB.Containers("modules")
For Each docModule In cntModule.Documents
debug.print "Module: " & docModule.Name
Next docModule
What I'd like to do next is open an module object: in that remoted database:
Set cntModule = LookupDB.Containers("modules")
For Each docModule In cntModule.Documents
debug.print "Module: " & docModule.Name
DoCmd.OpenModule docModule.Name
Next docModule
But I get the run-time error '2516': Microsoft Office Access can't find the
module 'Convert ISBNs.' [the name of the module in the remote database]
I'm assuming the reason I get this error is because the syntax I'm using is
causing the interpreter to look in the CurrentDB, which does not contain the
module called "Convert ISBNs", instead of the remote db, which does.
So, how do I reference a module in a connected database?
Thank you.
works. What I'd like to do now is open each module to get at the module
properties.
The following code snippet works to list the modules in a connected
database:
Set cntModule = LookupDB.Containers("modules")
For Each docModule In cntModule.Documents
debug.print "Module: " & docModule.Name
Next docModule
What I'd like to do next is open an module object: in that remoted database:
Set cntModule = LookupDB.Containers("modules")
For Each docModule In cntModule.Documents
debug.print "Module: " & docModule.Name
DoCmd.OpenModule docModule.Name
Next docModule
But I get the run-time error '2516': Microsoft Office Access can't find the
module 'Convert ISBNs.' [the name of the module in the remote database]
I'm assuming the reason I get this error is because the syntax I'm using is
causing the interpreter to look in the CurrentDB, which does not contain the
module called "Convert ISBNs", instead of the remote db, which does.
So, how do I reference a module in a connected database?
Thank you.