1 Line Compiled Macro Crashes

Technical support and scripting issues

Moderators: Dorian (MJT support), JRL

Post Reply
james107504
Newbie
Posts: 3
Joined: Sat Apr 26, 2003 9:42 am
Location: Colorado
Contact:

1 Line Compiled Macro Crashes

Post by james107504 » Fri Oct 10, 2003 7:43 am

I tried making a single line macro to move the cursor to the very corner of the desktop so it wouldn't be visible during desktop recording. The macro consists of only the following line:

MouseMove>1023, 767

From Macro Scheduler's main window, this macro executes correctly every time. Then i tried compiling the macro and it crashes on execution intermittently, working half the time and crashing the other half. The first time i execute the compiled macro after a reboot always results in a crash.

I'm working from a fresh installation of Windows XP Pro SP-1 with all the updates, a desktop resolution of 1024x768, and only Macro Scheduler 7.2.040 installed.

The crash error message reads:

"0.exe has encoutered a problem and needs to close. We are sorry for the inconvience."

Error details reveal that kernal32.dll may be involved. This should be fairly easy to duplicate if you have to option to compile macros. Can anyone duplicate this error, and are there any recommendations as to a solution?

Thanks,
James

User avatar
Bob Hansen
Automation Wizard
Posts: 2475
Joined: Tue Sep 24, 2002 3:47 am
Location: Salem, New Hampshire, US
Contact:

Post by Bob Hansen » Fri Oct 10, 2003 2:13 pm

IGNORE these first remarks.....just a record of the thought process, turns out to be wrong..... :oops:

I will try to compile later, but was wondering if you need to have a SetFocus> line in there first?

END of section to ignore.......
=======================
I was able to duplicate the problem. :cry:
Also able to correct it. This may work for you.:lol:

Using MacroScheduler 7.2.40, Win98SE, 800x600.
I compiled the single line
I made a desktop shortcut to the compiled script.
I closed all windows, double clicked on icon and had troubles.

:idea: Based on earlier compiled scripts, I remembered a past problem:
I edited the properties of the icon and found that the Target and Start In fields had mapped drive letters in them. I changed the Mapped Drive letters to UNC, did Apply and saved.
Example:
From:Q:\Data\MacroScheduler\Compiled\Forum\HideMouse.exe
To:\\SNAP126272\SHARE1\Data\MacroScheduler\Compiled\Forum.HideMouse.exe

Double clicking on icon is now making cursor disappear every time, with no problem.

:!: Conclusion: When making shortcuts for compiled Macro Scheduler, always use UNC vs. Mapped Drive letters.
Hope this was helpful..................good luck,
Bob
A humble man and PROUD of it!

User avatar
Captive
Macro Veteran
Posts: 213
Joined: Sun Oct 20, 2002 8:37 pm
Location: Colorado, USA

Re: 1 Line Compiled Macro Crashes

Post by Captive » Tue Oct 21, 2003 3:12 pm

james107504 wrote:MouseMove>1023, 767
Does it still crash if you remove the space between the comma/numbers?

User avatar
Bob Hansen
Automation Wizard
Posts: 2475
Joined: Tue Sep 24, 2002 3:47 am
Location: Salem, New Hampshire, US
Contact:

Post by Bob Hansen » Wed Oct 22, 2003 2:13 am

Hey, nice catch captive......that could be it!

Curious to see actual cause. No feedback since submitted on 10/10.
Hope this was helpful..................good luck,
Bob
A humble man and PROUD of it!

james107504
Newbie
Posts: 3
Joined: Sat Apr 26, 2003 9:42 am
Location: Colorado
Contact:

Post by james107504 » Wed Oct 22, 2003 1:54 pm

Thanks for the advice -- and sorry for leaving you hanging. I had to temporarily disconnect my workstation running Macro Scheduler, so i haven't been able to script or troubleshoot for a couple weeks.

Bob - Unfortunately your suggestion doesn't apply to my situation. All the files are on the same drive as the opertaing system (C: ). I've tried running the compiled macro directly from the Macro Scheduler directory and from the desktop, as well as running shortcuts to the same locations.

Captive - Sorry, the space is a typo. My primary (read: internet) workstation and test (read: Macro Scheduler) workstation are across from each other, and i must have inadvertently added the space while looking back-and forth between the two. I created the macro using Macro Scheduler's recorder, and i simply deleted all lines except the line containing the MouseMove command.

So, the script actually reads:

Code: Select all

MouseMove>1023,767
The line is terminated with a carriage return, so in the script editor shows that there are actually two lines of code: the MouseMove line and a blank line. Since there's no space after the comma, i'll try adding one. I'll also try removing the carriage return at the end of the line, or adding more trailing blank lines.

I'll be out of town again until the end of the week, but will let you know at the beginning of next week how things turn out. Again, thanks for all the advice.
James

HPROS
Junior Coder
Posts: 35
Joined: Tue Sep 16, 2003 7:52 pm
Location: Columbia, CT
Contact:

Post by HPROS » Tue Nov 04, 2003 10:33 pm

I compiled your line of code using MacroScheduler 7.2.40 on a Windows XP Pro version 5.1 Build 2600.xpclnt.....
I created a shortcut and tested it 10 times without issue. I have made calls to the compiled .ene and it executes fine every time.

I can not duplicate the error - Sorry. :?

Steve

Post by Steve » Mon May 10, 2004 3:57 am

I had a similar issue, and I added the code

CapsOff

prior to my MouseMove> command and it solved the problem for me.

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