Breakpoint is not working

General Macro Scheduler discussion

Moderators: JRL, Dorian (MJT support)

Post Reply
Jerryth31
Newbie
Posts: 19
Joined: Wed Jun 18, 2008 6:03 pm

Breakpoint is not working

Post by Jerryth31 » Thu Jun 19, 2008 4:35 am

I have tried setting breakpoints but then when I Run the code, it goes right by.

The Breaks have been in non logic sections (the script has to hit them).

Is there anything special I need to do?

Thanks

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

Post by Marcus Tettmar » Thu Jun 19, 2008 8:30 am

Which version are you running?

It's pretty simple. You need to open the Advanced Editor. Perhaps you're trying to run it elsewhere:

- Open the Advanced Editor (either from the macro properties dialog using the "Advanced Editor" button, or direct from the main toolbar (Edit Script).

- Put the cursor where you want the breakpoint.

- Click on the Debug menu and select Insert Breakpoint

- By default the Run button will run from the top but you may have changed that under the Debug menu, in which case it will run from the line the cursor is on. If the former just hit run and the macro will run from top to and stop at the breakpoint. If the latter, put the cursor on the line you want to start running from first.

- When the breakpoint is hit the debugger will go into Step mode. You can now either step line by line (key F8 or Debug menu then Step), or run to the next breakpoint, or the end by hitting Run again. Or press stop to stop debugging.

See also:
http://www.mjtnet.com/blog/2006/05/17/use-the-debugger/
Marcus Tettmar
http://mjtnet.com/blog/ | http://twitter.com/marcustettmar

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

gdyvig
Automation Wizard
Posts: 447
Joined: Fri Jun 27, 2008 7:57 pm
Location: Seattle, WA

Breakpoints added during breakpoint session ignored

Post by gdyvig » Tue Nov 18, 2008 5:02 pm

Hi Marcus,

I am using MS ver10.

Breakpoints work provided they are set before you run your script in debug mode.

If while stepping through the code you see a place where you would like to set another breakpoint, you are allowed to do so. But the new breakpoint is ignored when you click "run" to advance to it.

Will future versions of the debugger allow breakpoints to be added and used without stopping the debug session? This would make the debugger much more intuitive and flexible.

Thanks,
Gale

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

Post by Marcus Tettmar » Tue Nov 18, 2008 5:10 pm

No, the script has to be read into memory before it can be executed. V11 will prevent you from being able to edit the script while it is being executed/debugged. Have you not tried the beta?

We can look into whether this is possible for a future version - beyond v11.
Marcus Tettmar
http://mjtnet.com/blog/ | http://twitter.com/marcustettmar

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

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