Monitor expressions and variables.
Sébastien Granjoux
seb.sfo@free.fr
Philip Chimento
philip.chimento@gmail.com
Jaume Planas
jplanas@itberga.com 2011
Gil Forcada
gilforcada@guifi.net 2013

# Watch expressions

Watch expressions, or watches for short, are expressions that the debugger evaluates and prints the result of every time the program is stopped; for example, after every single-step through the program.

# List watched expressions

Per obrir la finestra Seguiments, trieu Visualitza Seguiments en el menú principal.

Like local variables, all watch expressions are displayed in a tree with children used to represent structure or array members.

## Variable

The name of the variable or the expression.

## Value

The variable or expression value.

## Type

The type of the variable or of the expression result.

# Update watches

Watch expressions can be updated automatically as soon as the program is stopped or on user request.

To set a watch expression to update automatically:

In the Watches window, select the watch you want to update automatically. Right-click and check that Automatic Update if checked. If not, select it.

To update a watch expression manually:

In the Watches window, right click and select Update Watch to update the selected watch.

To update all watch expressions manually at once:

In the Watches window, right click and select Update all to update all watches at the same time.

# Add a watch on an expression

To add an expression to the watch list:

Trieu Depura Afegeix un seguiment... en el menú principal o feu clic amb el botó secundari a la finestra Seguiments i trieu Afegeix un seguiment....

Enter the expression to watch. Check Automatic Update if you want the expression to be evaluated each time the program is stopped.

An expression can be evaluated and then added as a watch like this:

Trieu Depura Inspecciona/avalua en el menú principal o feu clic amb el botó secundari a la finestra de l'Editor i trieu Inspecciona/avalua.

Click on Add button to add this expression to the watches list.

# Supressió d'un seguiment

You can remove an expression from the watches list.

In the Watches window, select the watch you want to remove, then right-click and select Remove Watch.

All watches can be removed at the same time.

In the Watches window, right-click and select Remove all.

# Changing the value of a variable

If a watch expression corresponds to a variable, you can change its value.

In the Watches window, select the variable you want to edit and double click in the Value column.

Enter the new value.