Jump to content

run a shortcut


Recommended Posts

can i run a shortcut using run? like

run("d:\program.lnk")

i keep getting error saying like "unable to execute external program".

i also try

_ShellExecute("d:\program.lnk")

also getting error like "cant find the file" or something like that.

am i doing something wrong? thx in advance.

Link to comment
Share on other sites

can i run a shortcut using run? like

run("d:\program.lnk")

i keep getting error saying like "unable to execute external program".

i also try

_ShellExecute("d:\program.lnk")

also getting error like "cant find the file" or something like that.

am i doing something wrong? thx in advance.

<{POST_SNAPBACK}>

Uh....try using the "start d:\file.lnk" in a RunWait(@comspec) line.

Check the help file for an excellent example.

Lofting the cyberwinds on teknoleather wings, I am...The Blue Drache

Link to comment
Share on other sites

thx.

funny function tho.

this works

RunWait(@ComSpec & " /c" & "start D:file")

these both bring up the open with window.

RunWait(@ComSpec & " /c" & "start D:\file")
RunWait(@ComSpec & " /c" & "start D:file.lnk")

this gives me an error like "windows cannot find D:\program."

RunWait(@ComSpec & " /c" & "start D:\program files\file")

its like it reads until a space.

Edited by dexxa
Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...