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
800
Display alternative text in a numeric cell
posted

I have a column that is a numeric. I have the cell type set to XamMaskedEditor. When the cell is a specific value that is predefined i.e. “255” I wish to not display 255 but put in some alternative text such as “Read-only”. I would also like this cell to be read-only.

FYI: I also know that this datarecord will be the first row in the grid.

All other cells in this column in the other rows would be editable.

Parents
  • 69686
    posted

    Hello,

    There are couple of options here :

    1. Disabling the cell when a value: You can create a style for the XamMaskededitor or the CellValuePresenter and create a trigger that targets the Value/content property of the CVP and set the IsEnabled property to false when it equals 255

    2. Displaying different value : You can either use a converter (IValueConverter) which you can appply at this field's Converter property or the ValueToDisplayTextConverter property of the XamMaskedEditor.

Reply Children