# Binding a widget's visibility to a global variable

You can bind the visibility of a widget to a global variable. The widget will be displayed dependent on the value of the global variable. Example: A warning can be displayed as soon as a certain temperature is exceeded.

1. Create a global variable (BOOL or numeric data type).

1. Start editing the real-time application.
2. In the menu bar, click Visualisation.
3. On the drawing area, select the widget whose visibility you want to bind to a global variable.
4. In the Properties, click the link button next to Visibility.
5. The link button is activated and orange.
6. In the Visibility list box, select the global variable you want to bind to the widget's visibility.

1. The visibility of the widget is bound to the global variable.

Creating a global variable