Run A Shortcut?
#2
Posted 20 March 2004 - 07:46 PM
Quote
Ive found out that the only way to run one of my "homemade" C++ apps via AutoIt is to run it via a shortcut. Nothing else does work.
Are you sure that you're using Run properly ?
Quote
Run ("filename", "workingdir", flag)
Example :
Example :
[ code='text' ] ( Popup )
Run ("CPlusPlusProgram.exe", "C:\MyPrograms", @SW_MAXIMIZE)
Are you sure that you are pointing "workingdir" to the correct directory ?
If you're C++ program is in the same directory as the AutoIt-script,
then you can use @ScriptDir instead of "C:\MyPrograms"
#13
Posted 08 April 2004 - 08:27 PM
josbe, on Mar 28 2004, 05:52 PM, said:
For this reason, the best way is to use the ', instead "
For example,
For example,
[ code='text' ] ( Popup )
Run(@ComSpec & ' /c start "c:/launcher.lnk"') <- W2000 Run(@ComSpec & ' /c start c:/launcher.lnk') <- W9x
@josbe or ezzetabi: I'm havin' a bit of trouble w/ this one... apparently it doesn't like to launch shortcuts that are located on the desktop? Dumb question: just add the .lnk to the end of the shortcut's title?
Here's my code:
[ code='text' ] ( Popup )
Run ( @ComSpec & ' /c start "C:\Documents and Settings\UserName\Desktop\shortcut.lnk"' )
No dice; error message below:
Quote
Cannot find the file 'C:\Documents' (or one of its components). Make sure the path and filename are correct and that all required libraries are available.
EDIT: Well, now I'm around that error message, but rather than launching the shortcut it gives me a dos-esk command prompt to a folder on my desktop... :mad:
This post has been edited by esfalk: 08 April 2004 - 08:30 PM
#16
Posted 17 May 2007 - 10:28 PM
well i try to make a program that runs a shortcut from the desktop or better say the internet PPPoE i want to run but i cant make it work
can someone help me ???
the problem is that is working too fast i mean i cant see nothing :|
or can you give me some idea or source code of some how i can run a internet conection shortcut ??? ( i want to make to auto start my internet conection with out going in control panel -> network connection -> rds -> enter
ok i find the problem :D
my god ( i never think at that in all my life)
can someone help me ???
the problem is that is working too fast i mean i cant see nothing :|
or can you give me some idea or source code of some how i can run a internet conection shortcut ??? ( i want to make to auto start my internet conection with out going in control panel -> network connection -> rds -> enter
[ code='text' ] ( Popup )
Run ( @ComSpec & ' /c "C:\Users\All Users\Desktop\rds.ink"' )
ok i find the problem :D
[ code='text' ] ( Popup )
#include <Process.au3> _RunDOS("ncpa.cpl")
my god ( i never think at that in all my life)
This post has been edited by mircea: 17 May 2007 - 11:11 PM
#17
Posted 06 April 2009 - 12:04 PM
i am having the same problem
nothing happens when the script is run, it just sits there, how the heck do i launch a shortcut? the above posts have done nothing to help me i have followed all
[ code='text' ] ( Popup )
Run ( @ComSpec & '/c C:\Documents and Settings\Aria\Desktop\BitComet.lnk"' )
nothing happens when the script is run, it just sits there, how the heck do i launch a shortcut? the above posts have done nothing to help me i have followed all

Sign In
Register
Help
MultiQuote