Opening another instance of access.

G

Guest

I have created two separate DB's and wish to access the seccond db via a
command button/switchbord command from the first (main), and i am currently
not able to do so. (it's coming up with errors, as i am using the 'Run
application' command wizard.)

could someone please advise me of the code required to open another DB and
be able to work in it.

Both of the DB's share part o the same backend but only one makes changes to
the stored data

Thanks
 
G

Guest

Hi

Create a button and place this behind the OnClick event

Call Shell("""C:\Program Files\Microsoft Office\OFFICE11\MSACCESS.EXE""
""C:\Documents and Settings\UKOPS\My Documents\NAMEofDATABASE.mdb""", 1)


Notes
Microsoft Office\OFFICE11\MSACCESS
I assume you are using Office11
If not change this

C:\ I assum you are working on C -
if not change this

C:\Documents and Settings\UKOPS\My Documents\NAMEofDATABASE.mdb
Insert the full path to the DB
A tip = if you don't know the path. Click Start / Run / Browse to the DB
then click Open. DON'T RUN - but click the the path in the run dialog box
and paste it into the code above.

Have fun

Hope this helps
 
G

Guest

Hi Wayne,

thanks for that worked a treat.... only one more bug....

when i try to exit the second db it states "There was ana error executing
the command"

i assume that this is because i am using the Exit application function,
could you please advise on the code to close the second db.

thanks again.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top