I am using a doubleTextBox from Syncfusion. The Value is bound to a Property in a ViewModel class via
myDoubleTextBox.DataBindings.Add("BindableValue", mViewModel, "myProperty");
This works fine, however i want to be able to assign NULL
as well which should cause the DoubleTextBox
to show the value of its NullString
Property (means i want to exchange "double myProperty" for the nullable type "double?
myProperty"). I found some forum posts from 2007 which state that DoubleTextBoxes
support null values, but all examples that i found use outdated versions with Properties that don't exist anymore.
When i just try to bind NULL
to the BindableValue
of the Textbox
, the application crashes on calling myForm.Show()
with the following errormessage (caused by myProperty)
"Der Objektverweis wurde nicht auf eine Objektinstanz festgelegt" (meaning that the object reference does not point to the instance of an object).
Do you have any ideas? Thanks in advance!