Home |
Search |
Today's Posts |
#1
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
how do I run a .lnk file from VBA? I have tried the shell command but with no success. Any help appreciated.
|
#2
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Something like this may work for you:
Declare Function ShellExecute Lib "shell32.dll" Alias "ShellExecuteA" _ (ByVal hwnd As Long, ByVal lpOperation As String, _ ByVal lpFile As String, ByVal lpParameters As String, _ ByVal lpDirectory As String, ByVal nShowCmd As Long) As Long Sub a() ShellExecute 0, "open", "C:\MyLink.lnk", "", "c:\", 1 End Sub -- Jim Rech Excel MVP "Newbie" wrote in message ... | how do I run a .lnk file from VBA? I have tried the shell command but with no success. Any help appreciated. |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
shortcut has change or move so this shortcut can not open | Excel Worksheet Functions | |||
Shortcut key not running macro properly | Excel Discussion (Misc queries) | |||
Shortcut to : key | Excel Discussion (Misc queries) | |||
shortcut key not not running macro's all of a sudden | Excel Programming | |||
Running a macro from a desktop icon shortcut | Excel Programming |