NumberBox.Value Property

Definition

Gets or sets the numeric value of a NumberBox.

public:
 property double Value { double get(); void set(double value); };
/// [get: Microsoft.UI.Xaml.CustomAttributes.MUXPropertyChangedCallback(enable=true)]
/// [get: Microsoft.UI.Xaml.CustomAttributes.MUXPropertyDefaultValue(value="std::numeric_limits<double>::quiet_NaN()")]
/// [set: Microsoft.UI.Xaml.CustomAttributes.MUXPropertyChangedCallback(enable=true)]
/// [set: Microsoft.UI.Xaml.CustomAttributes.MUXPropertyDefaultValue(value="std::numeric_limits<double>::quiet_NaN()")]
double Value();

void Value(double value);
/// [Microsoft.UI.Xaml.CustomAttributes.MUXPropertyChangedCallback(enable=true)]
/// [Microsoft.UI.Xaml.CustomAttributes.MUXPropertyDefaultValue(value="std::numeric_limits<double>::quiet_NaN()")]
/// [get: Microsoft.UI.Xaml.CustomAttributes.MUXPropertyChangedCallback(enable=true)]
/// [get: Microsoft.UI.Xaml.CustomAttributes.MUXPropertyDefaultValue(value="std::numeric_limits<double>::quiet_NaN()")]
/// [set: Microsoft.UI.Xaml.CustomAttributes.MUXPropertyChangedCallback(enable=true)]
/// [set: Microsoft.UI.Xaml.CustomAttributes.MUXPropertyDefaultValue(value="std::numeric_limits<double>::quiet_NaN()")]
double Value();

void Value(double value);
public double Value { [Microsoft.UI.Xaml.CustomAttributes.MUXPropertyChangedCallback(enable=true)] [Microsoft.UI.Xaml.CustomAttributes.MUXPropertyDefaultValue(value="std::numeric_limits<double>::quiet_NaN()")] get; [Microsoft.UI.Xaml.CustomAttributes.MUXPropertyChangedCallback(enable=true)] [Microsoft.UI.Xaml.CustomAttributes.MUXPropertyDefaultValue(value="std::numeric_limits<double>::quiet_NaN()")] set; }
[Microsoft.UI.Xaml.CustomAttributes.MUXPropertyChangedCallback(enable=true)]
[Microsoft.UI.Xaml.CustomAttributes.MUXPropertyDefaultValue(value="std::numeric_limits<double>::quiet_NaN()")]
public double Value { [Microsoft.UI.Xaml.CustomAttributes.MUXPropertyChangedCallback(enable=true)] [Microsoft.UI.Xaml.CustomAttributes.MUXPropertyDefaultValue(value="std::numeric_limits<double>::quiet_NaN()")] get; [Microsoft.UI.Xaml.CustomAttributes.MUXPropertyChangedCallback(enable=true)] [Microsoft.UI.Xaml.CustomAttributes.MUXPropertyDefaultValue(value="std::numeric_limits<double>::quiet_NaN()")] set; }
var double = numberBox.value;
numberBox.value = double;
Public Property Value As Double

Property Value

Double

double

Attributes
Microsoft.UI.Xaml.CustomAttributes.MUXPropertyChangedCallbackAttribute Microsoft.UI.Xaml.CustomAttributes.MUXPropertyDefaultValueAttribute

Remarks

Text exists to faciliate getting the string representation of this property's numeric contents without the need for type conversion. Note the content of this property will overwrite the content of Text in initial set up. After the initial set up, changes to one will be progrogated to the other, but consistently making programmatic changes through this property helps avoid any conceptual misunderstanding that NumberBox will accept non-numeric characters through the Text property.

Applies to