Cyote101 Posted March 2, 2008 Share Posted March 2, 2008 I had created a small script and copiled it to an EXE file, everything works great on my computer. When i sent to to someone else, they got an error. "Unable to Run Script" has anyone else run into such problems? or does anyone know how to fix this. Here is a sample of the script i compiled $pos = MouseGetPos() MouseMove($pos[0], $pos[1] - 100) MouseDown("right") MouseUP("right") Send("p") Send("p") Link to comment Share on other sites More sharing options...
PsaltyDS Posted March 3, 2008 Share Posted March 3, 2008 I had created a small script and copiled it to an EXE file, everything works great on my computer. When i sent to to someone else, they got an error. "Unable to Run Script" has anyone else run into such problems? or does anyone know how to fix this. Here is a sample of the script i compiled $pos = MouseGetPos() MouseMove($pos[0], $pos[1] - 100) MouseDown("right") MouseUP("right") Send("p") Send("p") I don't see "Unable to Run Script" in that code. Where did this message come from? Valuater's AutoIt 1-2-3, Class... Is now in Session!For those who want somebody to write the script for them: RentACoder"Any technology distinguishable from magic is insufficiently advanced." -- Geek's corollary to Clarke's law Link to comment Share on other sites More sharing options...
GEOSoft Posted March 3, 2008 Share Posted March 3, 2008 I have a hunch that the other machine was Vista. Try putting #RequireAdmin at the top of your script. George Question about decompiling code? Read the decompiling FAQ and don't bother posting the question in the forums.Be sure to read and follow the forum rules. -AKA the AutoIt Reading and Comprehension Skills test.*** The PCRE (Regular Expression) ToolKit for AutoIT - (Updated Oct 20, 2011 ver:3.0.1.13) - Please update your current version before filing any bug reports. The installer now includes both 32 and 64 bit versions. No change in version number. Visit my Blog .. currently not active but it will soon be resplendent with news and views. Also please remove any links you may have to my website. it is soon to be closed and replaced with something else. "Old age and treachery will always overcome youth and skill!" Link to comment Share on other sites More sharing options...
Cyote101 Posted March 3, 2008 Author Share Posted March 3, 2008 The error is "Unable to open the script file" and the computer they are using is windows XP. The exe is running off of a CD, when i had them copy it to their HD they got the same error? Thanks, Any Ideas? Link to comment Share on other sites More sharing options...
Kerros Posted March 3, 2008 Share Posted March 3, 2008 When you complied the script, did it by chance create a secondary file with the same name, but a different extension? I have noticed that occurring to some of my scripts in the past. When that does happen I need to have both files to run the script correctly. Kerros Kerros===============================================================How to learn scripting: Figure out enough to be dangerous, then ask for assistance. Link to comment Share on other sites More sharing options...
GEOSoft Posted March 3, 2008 Share Posted March 3, 2008 (edited) The error is "Unable to open the script file" and the computer they are using is windows XP. The exe is running off of a CD, when i had them copy it to their HD they got the same error? Thanks, Any Ideas?Well I hate to say it but I think you should post the code. Something is definitly wrong. You didn't do something foolish like use ShellExecute("Myscript.au3") did you? Edited March 3, 2008 by GEOSoft George Question about decompiling code? Read the decompiling FAQ and don't bother posting the question in the forums.Be sure to read and follow the forum rules. -AKA the AutoIt Reading and Comprehension Skills test.*** The PCRE (Regular Expression) ToolKit for AutoIT - (Updated Oct 20, 2011 ver:3.0.1.13) - Please update your current version before filing any bug reports. The installer now includes both 32 and 64 bit versions. No change in version number. Visit my Blog .. currently not active but it will soon be resplendent with news and views. Also please remove any links you may have to my website. it is soon to be closed and replaced with something else. "Old age and treachery will always overcome youth and skill!" Link to comment Share on other sites More sharing options...
Cyote101 Posted March 3, 2008 Author Share Posted March 3, 2008 This is the Code of my Script $pos = MouseGetPos() MouseMove($pos[0], $pos[1] - 100) MouseDown("right") MouseUP("right") Send("p") Send("p") Link to comment Share on other sites More sharing options...
GEOSoft Posted March 3, 2008 Share Posted March 3, 2008 And what makes you think it's not working? It could be that there is a difference in the way the mouse buttons are set up. If the other person is left handed then the buttons have probably been switched. Better to use "Primary" or "Secondary" as the situation requires. It the mouse is set up for right-handed then the "Right" button is the one on the right which is also the "Secondary". If it's set up left-handed then the button on the right is the "Primary". So if you are right-handed and the code works for you then change the MouseUp() and MouseDown() lines to "Secondary". I think I got that straight. George Question about decompiling code? Read the decompiling FAQ and don't bother posting the question in the forums.Be sure to read and follow the forum rules. -AKA the AutoIt Reading and Comprehension Skills test.*** The PCRE (Regular Expression) ToolKit for AutoIT - (Updated Oct 20, 2011 ver:3.0.1.13) - Please update your current version before filing any bug reports. The installer now includes both 32 and 64 bit versions. No change in version number. Visit my Blog .. currently not active but it will soon be resplendent with news and views. Also please remove any links you may have to my website. it is soon to be closed and replaced with something else. "Old age and treachery will always overcome youth and skill!" Link to comment Share on other sites More sharing options...
Cyote101 Posted March 3, 2008 Author Share Posted March 3, 2008 Kerros, Thanks, You were on the right Track I have resolved the Problem, by having both the exe and the compiled script code both together on the CD in the Same directory. George, you brought up a good point i will change the script with the "Primary" "secondary" method. Thanks, very good point! Thanks to every one else too for your help! Link to comment Share on other sites More sharing options...
nixsoft Posted April 1, 2008 Share Posted April 1, 2008 I downloaded and re-installed both SCITE and AutoIT with the latest versions and all is OK now. Link to comment Share on other sites More sharing options...
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