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
355
"refresh" xamlwebgrid?
posted

Got another tough issue that we're seeing in our Silverlight app.

Our xamwebgrid is bound to an observable collection data source, with multiple template columns for display. The itemtemplate and edittemplates are used, text blocks for item and text boxes for edit.

One of the features of our app is to show money values in different currencies. So we have logic to switch the currency to Euros from US$, and vice-versa. The conversion is done when the user switches, and then we update the values. A converter takes care of capturing the correct culture and a standard ToString("C0") makes the values show with the correct currency symbol.

Except in random cases. We've determined this is not a code issue on our part, it is basically a paint bug with the grid. What we see is that, somewhat randomly, the currency symbol does not change, and only on randomly selected rows. More importantly, if I scroll the offending records out of view, and scroll back, the symbol will display correctly! This is why I call it a paint bug.

What I was hoping to find was a method to call to force a refresh of the grid to ensure things are updated, but the closest I could find was UpdateLayout, which has no effect at all.

Any ideas?

Parents
No Data
Reply
  • 40030
    Offline posted

    Hi, 

    Well, calling InvalidateData() should do the trick.  However, i'd like to try to narrow down why the grid isn't invalidating. 

    Do you have a sample that you could attach that reproduces the problem?

    Thanks,

    -SteveZ

Children