Category / Section
Does SfNumericUpDown responds change in culture
Syncfusion NumericUpDown provides the feature of different type of Culture to mention currency format.
To use Culture in SfNumericUpDown follow the below given procedure:
Step 1: Create the SfNumericUpDown with all necessary assemblies.
Step 2: Set FormatString to Currency format.
The below code illustrates the Culture in SfNumericUpDown:
C# Code
namespace NumericUPDown
{
public partial class NumericUPDownPage : ContentPage
{
public NumericUPDownPage()
{
InitializeComponent();
numericUpDown1.Culture = new System.Globalization.CultureInfo("hi-IN");
numericUpDown2.Culture = new System.Globalization.CultureInfo("en-US");
numericUpDown3.Culture = new System.Globalization.CultureInfo("de-DE");
numericUpDown4.Culture = new System.Globalization.CultureInfo("da-DK");
}
}
}
XAML Code
<StackLayout Padding = "20" > < Label Text="India" /> <numeric:SfNumericUpDown x:Name="numericUpDown1" FormatString="c" Value="5"/> <Label Text = "United States" /> < numeric:SfNumericUpDown x:Name="numericUpDown2" FormatString="c" Value="5"/> <Label Text = "German" /> < numeric:SfNumericUpDown x:Name="numericUpDown3" FormatString="c" Value="5"/> <Label Text = "Denmark" /> < numeric:SfNumericUpDown x:Name="numericUpDown4" FormatString="c" Value="5"/> </StackLayout>
Image for Different type of culture in SfNumericalUpDown:
|
