Expression and Value Monitors

The Monitored Expressions view and the Monitored Values view can both be used to display the contents of variables. Consider the following points when choosing where to monitor the variable. You can always place the variable in both views.

The Monitored Values view is useful for viewing the contents of objects allocated on the heap, particularly objects that are not easily accessible via an expression. For example, consider the case where you step into a class method. You can add the this pointer to the Monitored Expressions view to see its contents, but as soon as you return from the method, the expression is no longer valid, so no value is shown. But the storage that was pointed to by the this pointer is still valid, and you may still want to monitor the object. By adding the object to the Monitored Values view, you can keep track of the object contents even when there is no pointer name that explicitly and consistently points to it.



Add a Variable to the Monitored Expressions View
Add a Variable to the Monitored Values View
Change the Contents of a Variable
Change the Representation of a Variable