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

Security parameters to a VB6 ShellExecute command

Status
Not open for further replies.

vbprog1999

Programmer
Aug 5, 2004
1
US
If I execute a startdoc with this function I get the function to execute and
the access database executable works.

Function StartDoc(DocName As String) As Long
Dim Scr_hDC As Long
Scr_hDC = GetDesktopWindow()
StartDoc = ShellExecute(Scr_hDC, "Open", DocName, _
"", "C:\", SW_SHOWNORMAL)
End Function

r = StartDoc("F:\abc folder\abc application.mde")

This is where I need some help.

How do I send the parameters of a workgroup infromation file.

"C:\Program Files\Microsoft Office\Office\MSACCESS.EXE" "C:\Program
Files\abc\abc application.mde" /wrkgrp "C:\ABC\ABC Data\Data\abc workgroupinfofile.mdw"

....Everytime startdoc executes I get a "file not found" error. All the paths are from a short cut to the application on the desktop. That works.

Is there a way to just send an api call to the shortcut on the desktop?








Manage Your Profile |Rules of Conduct

 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top