Jump to content
Sign in to follow this  
Hirvesh

Passing A Variable To ShellExecute

Recommended Posts

Hirvesh

Hello, I've got a simple application which stores a path to an application like this:

$captureAppPath = "D:\Program Files Portable\FSCapture53\FSCapture53\FSCapture.exe"

I have been trying to execute the above application using ShellExecute as follows:

ShellExecute(FileGetShortName($captureAppPath))

However, the programs throws an error everytime like the one below:

ShellExecute($captureAppPath)
ShellExecute(^ ERROR
->14:17:50 AutoIT3.exe ended.rc:1
>Exit code: 1    Time: 2.156

Can anybody help me in understanding what I am doing wrong?

Share this post


Link to post
Share on other sites
JohnOne

First you say you are running it like this

ShellExecute(FileGetShortName($captureAppPath))

then the error says it has been ran like this

ShellExecute($captureAppPath)

Which is it, pick one.

And for the record both ways work just fine for me.

I suggest you post a whole reproducer code.


AutoIt Absolute Beginners    Require a serial    Pause Script    Video Tutorials by Morthawt   ipify 

Monkey's are, like, natures humans.

Share this post


Link to post
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
Sign in to follow this  

×

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.