I have a datagrid biding to nullable properties. For null values in DataGridTextColumn, instead of showing empty cell, I'd like to display 'n/a'. Is it possible?
You can use the TargetNullValue Property to set a default text if the binding returns null.
SAMPLE
<DataGridTextColumn Header="SomeText" Binding="{Binding
MyNullabeProperty,TargetNullValue=N/A}"/>
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With