Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save echristopherson/9561e78cf138b3a39949397bd63f6915 to your computer and use it in GitHub Desktop.
Save echristopherson/9561e78cf138b3a39949397bd63f6915 to your computer and use it in GitHub Desktop.
Public Sub CreateLNKFile(ByVal sShortcut As String, ByVal sFileLinkName As String)
'MsgBox "Creating shortcut to " & sFileLinkName & " at " & sShortcut & "."
Dim sh As Object
Dim link As Object
Set sh = CreateObject("WScript.Shell")
Set link = sh.CreateShortcut(sShortcut)
link.TargetPath = sFileLinkName
link.Save
End Sub
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment