When exporting an EXE...

Hints, tips and tricks for newbies

Moderators: Dorian (MJT support), JRL

Post Reply
only1platinum
Newbie
Posts: 15
Joined: Thu Aug 30, 2012 2:42 pm
Location: United States
Contact:

When exporting an EXE...

Post by only1platinum » Fri Sep 14, 2012 8:37 pm

I have a script that I have been working on for about the last week or so. It uses several instances of image recognition and work fine on my machine. I have the pro version because I will need to be able to run the scripts I create on other machines.

- I exported the exe, and saved it to the server...
- Created a shortcut on the local machine where the script will be run...
- Run the script and point it to the excel file that it needs to use to pull data...
- the exe will not find the buttons to click on to perform tasks. it just sits there till it times out.

I tried copying image files that I found where my script was first saved however I thought these would have been hardcoded to the EXE? I may be showing my ignorance here. It doesn't work with those images in the same folder as the exe.

even tried putting all files in the same folder on the local machine. Any help would be great. Thanks guys! You have been a great help already!

User avatar
Marcus Tettmar
Site Admin
Posts: 7395
Joined: Thu Sep 19, 2002 3:00 pm
Location: Dorset, UK
Contact:

Post by Marcus Tettmar » Fri Sep 14, 2012 9:14 pm

If the new machine has a different color depth, theme, system font setting and so on, then your images may need recapturing on that machine. Image Recognition is like-for-like. Also make sure the paths to the images are correct for the new machine (I always use %SCRIPT_DIR% so I only have to put the image in the same folder as the .exe/script).
Marcus Tettmar
http://mjtnet.com/blog/ | http://twitter.com/marcustettmar

Did you know we are now offering affordable monthly subscriptions for Macro Scheduler Standard?

only1platinum
Newbie
Posts: 15
Joined: Thu Aug 30, 2012 2:42 pm
Location: United States
Contact:

Post by only1platinum » Mon Sep 17, 2012 12:11 pm

Okay I will double check the screen color depth and see if I can fix that. How do I go about re capturing the images on that machine without installing Macro scheduler on that machine? I only have one license for the software.

User avatar
JRL
Automation Wizard
Posts: 3526
Joined: Mon Jan 10, 2005 6:22 pm
Location: Iowa

Post by JRL » Mon Sep 17, 2012 4:57 pm

One way would be to use the last script at the end of this thread.

Compile the script and you can use it where ever. When the script asks if you want to print, pick no. The image you selected is now in the clipboard. Open mspaint and paste the the image. finally, save the image to a bmp file from paint.

Post Reply
cron
Sign up to our newsletter for free automation tips, tricks & discounts