Debugging Ideas

Ideas for new features & functions

Moderators: Dorian (MJT support), JRL

Post Reply
Robbyn
Junior Coder
Posts: 43
Joined: Tue Feb 15, 2005 9:55 pm

Debugging Ideas

Post by Robbyn » Thu Jan 05, 2006 6:38 pm

I have really struggled with writing a particular script. It was not obvious why it was not working properly. I would have much appreciated the following:

1. A way of slowing down the code execution only if the script was run from within the editor, and in that mode the cursor moves down the script as it proceeds to run. This is important because the F8 step can not always be used to debug all of a program because even with version 8 the focus gets lost and the manual refocusing by clicking the mouse makes it difficult to know if there is a problem at that point.

2. A list of open windows as the script runs.

3. Button to run script from beginning an opposed to where the cursor has stopped.

4. A built in function to list all the files in a directory and its subs. I am aware that it can be done with extra code from within MS, but it would be much easier as an extension of the getfilelist function.
Robin

Robbyn
Junior Coder
Posts: 43
Joined: Tue Feb 15, 2005 9:55 pm

Post by Robbyn » Thu Jan 05, 2006 9:04 pm

Some more ideas:

1. Have the ability to continue at full speed after a breakpoint.

2. let two breakpoints in a script mean that debug mode starts at the first and stops at the second with the script continuing normally.

3. Prevent the scriptr from being changed if the script is being run in debug mode. I have found the script can be added to by a command if the focus goes to the editor rather than the program being run. Set focus does not always stop this in debug mode.

4. Have the list of windows proposed in my earlier posting be only those windows opening since the starting of MS and have the option to restrict the windows to those that are sent to the screen. Also allow only those windows being opened by specified programs. I have over 1400 windows open and it is difficult to spot what is new and what it relates to.
Robin

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

Re: Debugging Ideas

Post by Marcus Tettmar » Thu Jan 05, 2006 10:24 pm

Robbyn wrote:1. A way of slowing down the code execution only if the script was run from within the editor, and in that mode the cursor moves down the script as it proceeds to run. This is important because the F8 step can not always be used to debug all of a program because even with version 8 the focus gets lost and the manual refocusing by clicking the mouse makes it difficult to know if there is a problem at that point.
This functionality already exists. It's called Trace. You can set it to trace with 1 second multiple delays. So it can run each line every second, every two seconds ... whatever. Do Debug/Trace
2. A list of open windows as the script runs.
You can leave View System Windows open while debugging. Although you'd have to refresh it at intervals. Great idea for a future version.
3. Button to run script from beginning an opposed to where the cursor has stopped.
Ok, but all it would do is move cursor to start of script. You could do this anyway.
4. A built in function to list all the files in a directory and its subs. I am aware that it can be done with extra code from within MS, but it would be much easier as an extension of the getfilelist function.
Agree that would be nice. Will add to wish list.
Marcus Tettmar
http://mjtnet.com/blog/ | http://twitter.com/marcustettmar

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

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

Post by Marcus Tettmar » Thu Jan 05, 2006 10:25 pm

Robbyn wrote:Some more ideas:

1. Have the ability to continue at full speed after a breakpoint.

2. let two breakpoints in a script mean that debug mode starts at the first and stops at the second with the script continuing normally.

3. Prevent the scriptr from being changed if the script is being run in debug mode. I have found the script can be added to by a command if the focus goes to the editor rather than the program being run. Set focus does not always stop this in debug mode.

4. Have the list of windows proposed in my earlier posting be only those windows opening since the starting of MS and have the option to restrict the windows to those that are sent to the screen. Also allow only those windows being opened by specified programs. I have over 1400 windows open and it is difficult to spot what is new and what it relates to.
Great ideas. Thanks.
Marcus Tettmar
http://mjtnet.com/blog/ | http://twitter.com/marcustettmar

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

Robbyn
Junior Coder
Posts: 43
Joined: Tue Feb 15, 2005 9:55 pm

Post by Robbyn » Thu Jan 05, 2006 10:38 pm

Robbyn wrote:
1. A way of slowing down the code execution only if the script was run from within the editor, and in that mode the cursor moves down the script as it proceeds to run. This is important because the F8 step can not always be used to debug all of a program because even with version 8 the focus gets lost and the manual refocusing by clicking the mouse makes it difficult to know if there is a problem at that point.


This functionality already exists. It's called Trace. You can set it to trace with 1 second multiple delays. So it can run each line every second, every two seconds ... whatever. Do Debug/Trace
I am aware of trace but in my version of MS the cursor does not track the lines of the program. I have been doing:

1. Debug->trace->go
2. Run

When I do that the cursor does not move so I can not see which line is being executed.
Robin

IanSmith
Junior Coder
Posts: 24
Joined: Tue Jul 12, 2005 2:31 pm

Post by IanSmith » Fri Jan 06, 2006 10:48 am

Hi Marcus,

Can I second the request for a 'start from the start' button? I know we can jump to the top of the script, but when you are working with an eight hundred line script and no wheel mouse it can be a pain :)

Take care, Ian

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

Post by Captive » Sat Jan 07, 2006 12:20 am

Windows keyboard shortcut CTRL + HOME will move to the top of the page.

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