Parker Software Ltd Homepage
Forum Home Forum Home > ThinkAutomation Business Process Automation > ThinkAutomation Version 4
  New Posts New Posts RSS Feed - Script debug
  FAQ FAQ  Forum Search   Events   Register Register  Login Login

Script debug

 Post Reply Post Reply
Author
Message
GenTent View Drop Down
New User
New User
Avatar

Joined: 22 Jul 2014
Location: NH
Points: 14
Post Options Post Options   Thanks (0) Thanks(0)   Quote GenTent Quote  Post ReplyReply Direct Link To This Post Topic: Script debug
    Posted: 19 Nov 2018 at 11:08am
Is there a guide to the thinkautomation script debugger?  I'd like to know how to set a breakpoint that will bring up the debugger with live data...or alternatively how to set some accountvariable values upon entry so i can walk through the code. 
thanks,
Mark Carpenter
www.gentent.com
WeaterProof Your Power!
Back to Top
paul.oconnor View Drop Down
Admin Group
Admin Group
Avatar

Joined: 14 Dec 2015
Location: US
Points: 34
Post Options Post Options   Thanks (0) Thanks(0)   Quote paul.oconnor Quote  Post ReplyReply Direct Link To This Post Posted: 20 Nov 2018 at 9:13am
Hi Mark,

We are in the process of developing extensive guides for our applications. Currently we do not have one available at the moment that would detail this information.

As for the breakpoints, simply click on the grey column left of the script screen as seen below to add breakpoints. Select the "Play" button to initiate the debugger and in the "Immediate" window to call the functions to see variable values.




Regards,
Paul O
Back to Top
GenTent View Drop Down
New User
New User
Avatar

Joined: 22 Jul 2014
Location: NH
Points: 14
Post Options Post Options   Thanks (0) Thanks(0)   Quote GenTent Quote  Post ReplyReply Direct Link To This Post Posted: 20 Nov 2018 at 9:31am
Thank you Paul.  If you have any draft manuals and would like to get some customer usage feedback, I would be happy to "beta" test for you. 

I have figured out how to watch variables, set breakpoints, etc.  But I notice two things:
(1) Breakpoints work only in context of the script; ie, I cannot run my trigger actions (which have the live data) and cause a breakpoint to bring up the debug window
(2) I can't find a way to set variable data in the debug window.  This would somewhat mitigatethe need for #1 above.

Can you help in either of these two cases?

thakns
MArk
thanks,
Mark Carpenter
www.gentent.com
WeaterProof Your Power!
Back to Top
paul.oconnor View Drop Down
Admin Group
Admin Group
Avatar

Joined: 14 Dec 2015
Location: US
Points: 34
Post Options Post Options   Thanks (0) Thanks(0)   Quote paul.oconnor Quote  Post ReplyReply Direct Link To This Post Posted: 29 Nov 2018 at 8:53am
Hi Mark,

The scripting window is a bit tricky when it comes to debugging. During the debugging, you will have to set the variables inside the script in order to fully debug. An example would be:



The break point will need to be set after each defined variable. As you can see, even though I defined the variable in the script, I can still assign another value in the "Immediate" window. In return "Var3" variable now becomes 17 instead of 15.

? is used in the immediate window to call a variable to see what value it currently holds.

With that said, the debug window will not be able to call an extracted field variable or an account variable that is set outside of the script.

If you are looking to call this information and debug at the same time, it would be best if you copy the trigger and make that as a QA trigger. Then used the "Call AddToLog" syntax to display and results needed in the trigger process log. Also using the "End processing" action to facilitate ending the processing at a certain point (it's very own breakpoint).

Hope this helps with your query, and once I have the documentation near completion I'll definitely keep you in mind to review and provide suitable comments.

Regards,

Paul O
Back to Top
 Post Reply Post Reply
  Share Topic   

Forum Jump Forum Permissions View Drop Down

Forum Software by Web Wiz Forums® version 11.05
Copyright ©2001-2016 Web Wiz Ltd.

This page was generated in 0.047 seconds.