I want to Open a short cut on my desktop using VBA or MS Access

Dim a as Object
Dim str as string
Dim Target  As string
Dim Startin  AS string


Target = "C:\Program Files\Sage Software\V420JO\MAS90\Home\pvxwin32.exe" -hd ..\launcher\sota.ini ..\soa\startup.m4p -arg direct uion vbc "" JOB jt_timetrackerlaborimport_ui AUTO

Startin ="C:\Program Files\Sage Software\V420JO\MAS90\Home"
str = Target &  Startin
a = SHELL(str,vbNormalFocus)

daruffinAsked:
Who is Participating?
 
Jeffrey CoachmanMIS LiasonCommented:
daruffin,

Is your question simply: How to Open a Shortcut?
Or more specifically:  How to Open a Shortcut using the Shell command?

Because you can open a shortcut quite easily by treating it as a Hyperlink
Try something like this:

Application.FollowHyperlink "C:\Documents and Settings\user\Desktop\NameOfYourShortCut.lnk"

(If you get a hyperlink warning, you can disable it for good by seeing this link: http://support.microsoft.com/kb/829072/en-us)

JeffCoachman

0
 
jazzIIIloveCommented:
0
 
daruffinAuthor Commented:
This only tells me how to create a short cut I need to open a short cut using the shell command. I want to click a button on my MS Access form and open this short cut which is located on my desktop.
0
Ultimate Tool Kit for Technology Solution Provider

Broken down into practical pointers and step-by-step instructions, the IT Service Excellence Tool Kit delivers expert advice for technology solution providers. Get your free copy now.

 
daruffinAuthor Commented:
You keep sending me how to create a short cut. I want to run my shortcut which is already created on my desktop and This shortcut run another program. How can I run this short using the Shell command
0
 
daruffinAuthor Commented:
Let me try this and I will get back to you
0
 
daruffinAuthor Commented:
This worked out well
0
 
Jeffrey CoachmanMIS LiasonCommented:
;-)
0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.