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

two different access applications

Status
Not open for further replies.

esengul

Instructor
Dec 9, 2004
59
US
i have a button on the form with click event that opens a different access application. I have to get the variable from the first application and use it on the second one. Could you tell me how?
Thanks
 
Hi
Something like (?):
Code:
Sub DisplayExternalForm()
Dim appAccess As Access.Application
    strDB = "C:\Tek-Tips.mdb"
    ' Create new instance of Microsoft Access.
    Set appAccess = CreateObject("Access.Application")
    ' Open database in Microsoft Access window.
    appAccess.OpenCurrentDatabase strDB
    appAccess.Visible = True
    With appAccess
        ' Open form with OpenArgs
        .DoCmd.OpenForm "Form1", , , , , , "Hello"
        ' Or just use a control
        .Forms!Form1.Text1 = 123
    End With
End Sub
Is this what you had in mind?
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top