The RadNumericUpDown control provides the user with an interactive UI, that allows him to select numerical values. In order to use the
RadNumericUpDown control in your application you have to reference the following assemblies in your project:
- Telerik.Windows.Controls.Input.dll
- Telerik.Windows.Controls.Primitives.dll
Note |
|---|
|
To use the RadNumericUpDown control in Expression Blend you have to add reference to the
Telerik.Windows.Core.dll.
|
After adding references to the aforementioned dlls, you can declare a new RadNumericUpDown instance as any normal Silverlight control.
Note |
|---|
To use the RadNumericUpDown control in the XAML you have to add the following namespace declaration:
xmlns:telerikInput="clr-namespace:Telerik.Windows.Controls;assembly=Telerik.Windows.Controls.Input"
|
CopyXAML
<telerikInput:RadNumericUpDown x:Name="radNumericUpDown" />
CopyC#
RadNumericUpDown radNumericUpDown = new RadNumericUpDown();
Here is a snapshot of the result.
Getting the Selected Value
In order to get the numerical value selected by the user, the only thing you have to do is to access the value of the Value property. Here is an example.
CopyC#
double selectedValue = this.radNumericUpDown.Value;
Configuring the RadNumericUpDown
You are able to make the following configurations to the RadNumericUpDown control: