Debugger

Info about design forms features
PetrS
Site Admin
Posts: 181
Joined: 11 Jul 2014, 13:55

Debugger

Postby PetrS » 23 Jul 2014, 14:52

size=150Debugger/size
Version 0.1.62 and higher

Debugger is available in Design Forms 0.1.62 and higher.

buRun the script with debugger:/u/b
Click on the small arrow on the right side of "Refresh" button and select "Run script with debugger".
- or -
Press key shortcut (F6) in CodeEditor.

buSet BreakPoints:/u/b
BreakPoint is the point where the script execution is paused.
A breakpoint is a signal that tells the debugger to temporarily suspend execution of your app at a certain point. When execution is suspended at a breakpoint, your program is said to be in break mode. While being in break-mode, you can watch variables, trace listener and calculation output. Entering break mode does not stop or end the execution of your program; execution can be resumed at any time.
You can add as many breakpoints as you want. You can even add/remove breakpoints during the script execution.
BreakPoint is highlighted with red background.


buEntering extern CLC:/u/b
You can define break points in extern CLC (if you have source code for that).
list
*Click at the LoadExternCLC command in Code editor./*:m
*Press F12 to open source code of extern CLC (read only)./*:m
*Setup any breakpoints in extern CLC source code./*:m
*Run script with debugger/*:m/list:u


buStepping the instructions:/u/b
One of the most common debugging procedures is stepping. Stepping is executing script one instruction at a time. When you have halted execution, such as running the debugger to a breakpoint, you can use three debug commands to step through code:
list
*Next breakpoint (F6) - Continue in script execution until reach next breakpoint or reach the end of the script./*:m
*Step Into (F11) - If the line contains a function call or extern CLC, iStep Into/i executes only the call itself, then halts at the first instruction of the code inside the function. Otherwise, Step Into executes the next statement.
:!: If you want to step into extern CLC, you must open the source code first (see above)./*:m
*Step Over (F10) - If the line contains a function call or extern CLC, iStep Over/i executes entire function (extern CLC) and then halts at the next instruction./*:m/list:u


buModify variable values:/u/b
You can modify any variable property while being in break mode.
:idea: Table of variables always contains variables of the current variable scope (Master CLC, extern CLC, function, etc.)
Ing. Petr Slepicka
DesignForms Online
Engineering calculations online - EuroCode, AISC, statics
Automate your static calculations today!

PetrS
Site Admin
Posts: 181
Joined: 11 Jul 2014, 13:55

Re: Debugger

Postby PetrS » 06 Oct 2014, 09:26

size=150Handling exceptions/size
Version 0.1.65+

Debugger will automatically stop script execution on exception throwing instruction.
Ing. Petr Slepicka
DesignForms Online
Engineering calculations online - EuroCode, AISC, statics
Automate your static calculations today!

PetrS
Site Admin
Posts: 181
Joined: 11 Jul 2014, 13:55

Re: Debugger

Postby PetrS » 31 Oct 2014, 15:11

Debugger is now available also for CLCs using Concrete toolbox.
Ing. Petr Slepicka
DesignForms Online
Engineering calculations online - EuroCode, AISC, statics
Automate your static calculations today!

jkrsik
Posts: 30
Joined: 06 Oct 2014, 13:10

Re: Debugger

Postby jkrsik » 06 Jan 2016, 10:58

size=150Debugger improvements/size
Version P - 16.098.25+

The behaviour of variables under debugger was changed.
When debugger run, Table of variables is empty. User have to manually add the variables which he want to watch. The value of this variable is than dynamically changed in debugger.
All type of variables can be used, even local variables from functions.

attachment=0
Debugger.PNG
Adding variable to watch list under debugger
Debugger.PNG (42.05 KiB) Viewed 8015 times
/attachment


Return to “Design forms features”

Who is online

Users browsing this forum: No registered users and 5 guests