Call Stack

Old Content - visit altium.com/documentation

The following content has been imported from Legacy Help systems and is in the process of being checked for accuracy.

Function

The Call Stack panel enables you to view the chain of procedure/function calls that has led to the current point of execution in the script being debugged.

Content and Use

As you step-debug your script, the panel will show the name of any function or procedure that you enter.

When a call to another function or procedure is encountered, the panel will show the name of this additional function/procedure as it is entered. As the function/procedure is called from within a function/procedure, the original function/procedure is still displayed in the panel.


A 'call stack' is effectively set up, showing the relationship between descendant function/procedure calls. The original function/procedure appears at the bottom of the stack, with each subsequently called function/procedure above it, right up to the currently entered function/procedure on the top of the stack.
As script execution drops out of a sub-function/procedure and passes back into the calling function/procedure, the former will be removed from the stack and the calling function/procedure will become the top of the stack.
Double-clicking on an entry in the panel will jump to the corresponding line of script in which the call to the selected function or procedure is made. The line will be highlighted in the color associated with scripting errors and will have the scripting error marker displayed in the right-hand margin. This is purely used for highlighting purposes. It will disappear when you click on the document and does not inhibit the debug session in any way.
This can also be a quick way of defining the next point that you wish to run code execution to, using the Run To Cursor command available from the Run menu or Script Debug toolbar [shortcut: CTRL + F9].

Notes

  • The keyboard shortcuts Up Arrow (or Left Arrow), HOME, END and Down Arrow (or Right Arrow), can be used to select the previous, first, last and next entry in the stack, respectively.

See Also

You are reporting an issue with the following selected text and/or image within the active document: