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

Sart msaccess97 with commant shell

Status
Not open for further replies.

MARELUAD

Programmer
Jan 13, 2003
37
NL
How can I start access with parameters using visual basic?

This don't work......
Dim Q as long
Q = Shell("C:\Program Files\Microsoft Office 97\Office\msaccess.exe C:\Program Files\Test\TEST.mdb /Run ,"aaa","bbb", vbNormalFocus)

/Run is the macro in access
"aaa" is a parameter
"bbb" is a paremeter

I hop to get a example

Thanks


 
If You Set A Reference To The Access In Your Project It Is Easier And Provides Early Binding But This Can Be A Problem If People Have Different Versions Of Access So I Recommend Using The CreatObject Method Instead Of Early Binding.

' Early Binding
' Dim p_oAccess As Access.Application
' Set p_oAccess = New Access.Application

' Late Binding
Set p_oAccess = CreateObject("Access.Application")

p_oAccess.SetOption "OptionName", "Value"
...

p_oAccess.Visible = True


Here Is A Link To Some Information Regarding The Available Options.




 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top