Scenario 5 of 7 / 7 illustrated steps

Widgets in Action

Widgets are interactive components, not just visual decorations.

See property editing, live text, synchronized numeric controls, checkbox events, and spinner visibility.

In this scenario 7 steps · jump to a capture

Select any screenshot to enlarge it. Use ← / → to move between captures, Esc to close, and 100% to inspect original detail.

01

Configure the Slider in the Inspector

The Slider can be selected on the canvas or in the Design Explorer. Its initial value, range, and step are visible in the Inspector, along with access to the changed handler.

Why it matters Properties define the starting behavior; event handlers respond to interaction.

Selected Slider with initial value, range, step, and changed handler controls.
05.01 · Configure the Slider in the Inspector
02

Update a Label from a Button

In the running application, clicking Welcome sets the adjacent Label to “Welcome to VB-Rust!”. The Button and Label are connected by application behavior.

Why it matters A click can update another part of the interface.

Running application with the Welcome button and updated welcome label.
05.02 · Update a Label from a Button
03

Mirror text as it changes

“Live text” appears in the TextEdit field and in its neighboring Label. The annotation identifies the Label as a mirror of what is typed.

Why it matters Text-change handling provides immediate feedback while the user types.

TextEdit containing Live text and a Label showing the same text.
05.03 · Mirror text as it changes
04

Keep numeric controls synchronized

The Slider has moved to 100, and the DragValue control displays 100 as well. The capture demonstrates synchronized values in this sample, then points to “Open Form 2”.

Why it matters Related controls can represent the same changing application value.

Slider and DragValue both showing 100 in the running application.
05.04 · Keep numeric controls synchronized
05

Explore a second set of widgets

The second form contains a visible Spinner, a “Show / Hide Spinner” Button, a Checkbox, and a Label reading “No”. The Checkbox is initially unchecked.

Why it matters A second form groups another set of interactive behaviors.

Second form with visible Spinner, unchecked Checkbox, and No label.
05.05 · Explore a second set of widgets
06

Respond to a Checkbox change

The Checkbox is now checked and the Label reads “Yes”. The Spinner is still visible; its visibility is controlled separately by the “Show / Hide Spinner” Button.

Why it matters A checkbox event can update text without changing unrelated widget state.

Checked Checkbox with Yes label while the Spinner remains visible.
05.06 · Respond to a Checkbox change
07

Hide the Spinner and retain the check

After using “Show / Hide Spinner”, the Spinner is hidden. The Checkbox remains checked, and its Label still reads “Yes”.

Why it matters Visibility changes can be independent of the other state on a form.

Spinner hidden while the Checkbox stays checked and the label remains Yes.
05.07 · Hide the Spinner and retain the check

← Back to Home