Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations IamaSherpa on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Running other Access Databases with forms 2

Status
Not open for further replies.

JaySang

Technical User
Jun 26, 2003
43
CA
Whats the easiest or best way to launch other MS Access database on a form inside of your main database ?

I have a main central database and I want to link to other existing databases

any suggestions ?

Thanks Everyone!
 
Open the database with the ShellExecute command--all you have to do is pass in the database path and filename and it will open the second database for you in a new window.


If you use Access/JET security, ShellExecute to the shortcut to the database, if that makes any sense to you.





--
Find common answers using Google Groups:

Corrupt MDBs FAQ
 
I have used this method to launch an Access Project.

Public pubAppAccess As Access.Application
Public pubFilePath As String
Public pubStartWindow As String, pubObj As Object

' Open Access project.
pubFilePath = "C:projects\remotepubs.adp"
Set pubAppAccess = New Access.Application
pubAppAccess.OpenAccessProject pubFilePath

pubAppAccess.Application.RefreshDatabaseWindow
pubAppAccess.Application.Visible = True
DoCmd.Close
 
is there anyway you can lauch another app without the complete path like :
pubFilePath = "C:projects\remotepubs.adp"

I wan't the filename to be dynamic just incase the file moves anywhere. Are there any wildcards that will allow it to just start in the current directory ?? so i can just list the file name

Thanks In Advance
 
?left(currentdb.name, len(currentdb.Name)-len(dir(currentdb.Name)))

will return the current directory of the database opened. You can work the dynamic part from that starting point.
 
I'm confused what this is - ?left(currentdb.name, len(currentdb.Name)-len(dir(currentdb.Name)))

can i put that as my path - pubFilePath = "?left(currentdb.name, len(currentdb.Name)-len(dir(currentdb.Name)))\remotepubs.adp"

like that or do i put that in a varibale and put that in my path

can anyone please clarify

thanks
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top