Your Privacy Matters: We use our own and third-party cookies to improve your experience on our website. By continuing to use the website we understand that you accept their use. Cookie Policy
260
Binding an UltraNumericEditor to a Nullable Decimal.
posted

Hello,

I am working with version 20141.2035 and am trying to bind an UltaNumericEditor to a nullable property (NullableProperty).  I am doing the following

// designer settings

myUltraNumericEditor.FormatString = "#,###,###.#######";
myUltraNumericEditor.MaskDisplayMode = Infragistics.Win.UltraWinMaskedEdit.MaskMode.IncludeLiterals;
myUltraNumericEditor.MaskInput = "{double:9.6}";
myUltraNumericEditor.MaxValue = 1E+16D;
myUltraNumericEditor.MinValue = -1E+16D;
myUltraNumericEditor.Name = "ultraNumericEditorWireFxRate";
myUltraNumericEditor.Nullable = true;
myUltraNumericEditor.NumericType = Infragistics.Win.UltraWinEditors.NumericType.Decimal;
myUltraNumericEditor.PromptChar = ' ';

//code behind

public decimal? NullableProperty {get; set;}

myUltraNumericEditor.DataBindings.Add("Value", this, "NullableProperty", false, DataSourceUpdateMode.OnPropertyChanged);

I have no problems using this binding approach when using a non nullable decimal.

Thanks in advance for any help

Parents Reply Children