anandnz Posted January 30, 2011 Posted January 30, 2011 (edited) Hi Experts, I hit the wall and this time trying to run notepad++.exe from a command prompt. This is a sample excersice as actually wanted to run a big line of command for a third party. Any help is appreciated. #include <File.au3> $CR = 'notepad++.exe' $command = " C:\Program Files\Notepad++\" & $CR ConsoleWrite('@@ Debug(' & @ScriptLineNumber & ') : $command = ' & $command & @crlf & '>Error code: ' & @error & @crlf) ;### Debug Console ; Run($command); THIS DOES NOT SEEM TO WORK, HOWEVER WHEN I COPY THE OUTPUT IN "start" "run" it works not via Run command HELP HERE Edited January 30, 2011 by anandnz
somdcomputerguy Posted January 30, 2011 Posted January 30, 2011 Remove the leading space in the $command variable,so this: $command = " C:\Program Files\Notepad++\" & $CRbecomes this: $command = "C:\Program Files\Notepad++\" & $CR - Bruce /*somdcomputerguy */ If you change the way you look at things, the things you look at change.
anandnz Posted January 30, 2011 Author Posted January 30, 2011 Hi somedcomputerguy, Thank you very much. It works. cheers
somdcomputerguy Posted January 30, 2011 Posted January 30, 2011 You bet. Good luck! - Bruce /*somdcomputerguy */ If you change the way you look at things, the things you look at change.
Recommended Posts
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 accountSign in
Already have an account? Sign in here.
Sign In Now