Blazor Toolkit Numeric Textbox Component
Add the Numeric Textbox component in application as shown in below code example.
One-Way Binding
Bind the value using the Value parameter (no two-way sync). Updating the backing field programmatically reflects in the UI.
Two-Way Binding
Use bind-Value for two-way synchronization between the component and the bound field.
Percentage Format
Apply Format="P2" to display the value as a percentage when unfocused; underlying value remains numeric.
Currency Format
Use Format="C2" to render a currency using the current culture’s currency symbol and separators.
Custom Format (# And 0)
Combine # (optional digit) and 0 (zero placeholder) to build custom display patterns such as ###.## and 000.00.
Native Events (OnKeyPress)
Attach native DOM events directly on the component. This example logs the last key pressed via onkeypress.
Events
Wire component events such as Created, Focus, Blur, ValueChange.
Value: 30
Event: —