Open another db from VBA

D

David C

I have a tracking database in MSAccess which runs nicely.

Now I wish to launch this from within another MSAccess database in response
to a button click (using VBA, I guess).
- ideally, the first db would close itself after opening the tracker
- I experimentated with various code, best was Application.FollowHyperlink
("filename"), but I am not sure how stable the thing is, or what problems
this might create.
- Should this come before or after DoCmd.Close ?
 
F

fredg

I have a tracking database in MSAccess which runs nicely.

Now I wish to launch this from within another MSAccess database in response
to a button click (using VBA, I guess).
- ideally, the first db would close itself after opening the tracker
- I experimentated with various code, best was Application.FollowHyperlink
("filename"), but I am not sure how stable the thing is, or what problems
this might create.
- Should this come before or after DoCmd.Close ?

What does this question have to do with TableDesign, the topic of this
newsgroup?

Application.FollowHyperlink "c:\YourFolder\YourDatabase.mdb"
DoCmd.Quit
 
D

David C

Thanks Fred

{A little aggressive there?}

I posted this, I thought, to the MSAccess Database design group, which is
where the header says it resides. If you cannot help, please advise me where
best to seek answers.
 
F

fredg

Thanks Fred

{A little aggressive there?}

I posted this, I thought, to the MSAccess Database design group, which is
where the header says it resides. If you cannot help, please advise me where
best to seek answers.

I did help. I gave you the answer...
Application. FolowHyperlink followed by DoCmd.Quit.

Your topic has to do with VBA and would have better been posted in
either
microsoft.public.access.formscoding
or
microsoft.public.access.modulescoding
or
microsoft.public.access.modulesdaovba

I wasn't, and am not now, being 'aggressive'. Our time is valuable,
just as yours is. I think it makes sense to have your question (and
it's answer) placed where it will be seen by others with a similar
problem, so that we will not have to soon re-answer the same question
for some one else. That's why there are so many different Access
newsgroups.
 

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