When you’re going through the execution context, you are able to see all the locals of this part of the code. In the Locals panel, you can find all the variables, their names, types, and values. This helps you to trace each change of the variable's value or other attributes on every step of the execution process, so you can determine, for instance, what causes the error or the fail. With all the variables and all the data about them, you are able to understand the work of your code in a deeper detail.

The Locals panel

The Locals panel displays the variables that are defined in the local scope, which is generally the function or method that is currently being executed.

All the data is separated in three columns:

  • Name — the name of the local variable. The variables are displayed as a tree. Click on the arrow to the left of the variable name to expand the view to show fields and properties.
  • Value — the value that the variable has in the active scope. If the variable has the depending ones, its value is displayed as the name of the file, where it's placed. At the same time, the depending variable has exact values.
  • Type — the type of the variable: a string, boolean, object, integer, etc.

You can also see the type and value of the local variable from its context menu:

The context menu of the variable

NB: If you reached the Salesforce limits, the name of the variable may be cut. The same rule is also true for the values of variables.

The name of variable may be cut

In addition, the Locals panel includes also the properties with all the related data. Similar to the locals, the properties in the Locals panel may have different nesting levels. At the same time, here you can find the address value for the custom types of your Locals. If this value is specified, you will see it in the Locals panel in the Debug mode.

In this section:

This also may be useful:

Last modified: 2017/02/02 16:21

footer image