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 Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Opening access from access 1

Status
Not open for further replies.

accessgoddess

Programmer
Mar 20, 2002
10
0
0
US
Hi,

My client wants me to produce an access app that works as a menu system to open other access applications. I know how to use the appactivate statement to start access but how do I open the appropiate application as chosen by the user?

Thanks for your help.

Thanks again!

Joanne
 
Perhaps the menu item could run a Shell function which calls the desired app.
 
Put the path of the database in a table and use a combo box for selecting the database. I have this code in a combo box double click event.

Dim ctl As CommandButton
Dim strAddress As String
strAddress = [Your name of your combo box].Text
Set ctl = Me!Command0
With ctl

.Visible = False
.HyperlinkAddress = strAddress
.Hyperlink.Follow

End With
 
Try putting this code on the 'on click' event of a command button for each application.
Private Sub Garnishment_Click()
On Error GoTo Err_Garnishment_Click
Dim stAppName As String
stAppName = "C:\Program Files\Microsoft Office\office\MsAccess.exe ""(drive):\(application Name)"""
Call Shell(stAppName, 1)
Exit_Garnishment_Click:
Exit Sub
Err_Garnishment_Click:
MsgBox Err.Description
Resume Exit_Garnishment_Click
End Sub


 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top