Jump to content

Recommended Posts

Posted

Can anyone help me with my script. I tring to create a short cut that looks like this.

"C:\Program Files\Avant Browser\avant.exe" -install

Every command I try write the shortcut like this.

"C:\Program Files\Avant Browser\avant.exe -install"

Is this even possible with AutoIt?

Here is the commands I tring to use.

$name = @ProgramFilesDir & "\Avant Browser\avant.exe"

$place = $name & ' -install'

FileCreateShortcut(@DesktopDir & $place, @ProgramsCommonDir & "\Avant Browser.lnk")

Posted

Thanks. That fixed it. I see my stupid mistake. I was added it to the wrong place.

Thanks again.

  • 9 months later...
Posted

Excuse me, but I really want to know

How can I use relative path and file name to create shortcut?

I'v put the script file and the exe file in same folder.

Posted

Excuse me, but I really want to know

How can I use relative path and file name to create shortcut?

I'v put the script file and the exe file in same folder.

<{POST_SNAPBACK}>

link files donot have relative paths

Or they use environment variables or real absolute paths

Sometimes you can enter a relative path but windows just changes it to a absolute path when saving.

From what I know real relative paths are not possible in link files (shortcuts)

Its not a batch file.

Posted

link files donot have relative paths

Or they use environment variables or real absolute paths

Sometimes you can enter a relative path but windows just changes it to a absolute path when saving.

From what I know real relative paths are not possible in link files (shortcuts)

Its not a batch file.

Now I've found that I can use @ScriptDir MACRO to get the directory and use & to make the absolute path. Thanks anyway.

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
×
×
  • Create New...