FIND YOUR NEXT FEW LINES

Results for “Event control”

Small, practical examples. Search by task or narrow things down below.

166 snippets foundClear filters
Arduino / CGetting Started

Give an LED pin a constant name

Arduino / C: Use const to name the built-in LED pin and reuse it in output instructions.

Arduino / C✓ Tested
jQueryEvents

Handle a button click

Attach a jQuery click handler to update text.

jQuery✓ Tested
jQueryEvents

Handle a form locally

Prevent default form navigation while displaying input with jQuery.

jQuery✓ Tested
PowerShellFunctions & control

Handle a terminating error

Catch conversion failures and produce a clear fallback.

try catch✓ Tested
jQueryEvents

Handle dynamically added buttons

Delegate a jQuery event from a stable parent to later children.

jQuery✓ Tested
HTMLForm behavior

Include a nonvisible value in form data

HTML: A named hidden input contributes data without adding a visible editing control.

HTML✓ Tested
C++Tasks & synchronization

Increment a shared counter safely

C++: Atomic increments prevent lost updates when two threads change the same counter.

C++✓ Tested
Bash ScriptsArray operations

Join array items with a one-character separator

Bash Scripts: A local IFS controls the separator used by the quoted star expansion.

Bash Scripts✓ Tested
Bash ScriptsFunction scope & composition

Keep a function variable local

Bash Scripts: Local prevents an ordinary function assignment from replacing a caller variable.

Bash Scripts✓ Tested
HTMLForm behavior

Keep an action button from submitting a form

HTML: Specify type button for controls whose purpose is a local action.

HTML✓ Tested
Arduino / CTiming & control

Measure a short delay with micros

Measure elapsed microseconds around a short operation.

micros✓ Tested
jQueryEvents

Mirror input text

Update a result as the user types using a jQuery input event.

jQuery✓ Tested