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
430
Notification of cell value changed in XamPivotGrid
posted

Hi,

I am making changes to the underlying FlatDataSource of my XamPivotGrid and these changes are showing up nicely in the PivotGrid. However, I would like to handle a "valuechanged" event on the cells so that I can momentarily change the background colour of the cell to notify the user of the change.

I have tried to find an appropriate event to handle for this, but couldnt find anything on the PivotCellControl or the PivotCell.

Please could someone let me know where to look?

Thanks in advance.

Phil

Parents
  • 34810
    Verified Answer
    Offline posted

    Hello Phil,

    Thank you for your post!

    To start, I can tell you that there isn't any type of event on the XamPivotGrid or the PivotCell / PivotCellControl that can detect the value in the cell changing, unless you are actually doing so by editing the cells in the UI of the grid. From the sounds of it though, you are editing the data of your FlatDataSource in code, and so to get the changes to show up, I am under the impression that you are refreshing the XamPivotGrid after each modification is made. Please let me know if these impressions are incorrect.

    I had thought to recommend an implicit style for PivotCellControl that binds the Background property to the PivotCellControl's Cell.Data.Value property, so that when that value changes you would be able to utilize a converter to return the desired background color. The issue with this is that this converter will fire for every cell as it appears in the grid, and you will have no reference to the previous value in the cell, so you wouldn't be able to tell if that value has changed or not. Moreover, this converter will fire for each cell in the grid when you refresh the grid as well, because all of the PivotCellControls become new instances. You need to refresh the grid to show the new values, though.

    I would recommend that if you would like to see this functionality built in to the XamPivotGrid, that you submit a new product idea for it at http://ideas.infragistics.com. This site puts you in touch with our product management teams who plan and prioritize new products and features based on user input and feedback.

    Please let me know if you have any other questions or concerns on this matter.

    Sincerely,
    Andrew
    Associate Developer
    Infragistics Inc.
    www.infragistics.com/support

Reply Children
No Data