Skip to main content

The while row wasn't redrawn when we change the column's value




  • Dapfor Team


    We think you use the event-driven model and when the ParitetStrategyTraker.State property is changed, the object raises a protertychanged event with the “State” argument. Once the grid receives the notification, it computes cell’s rectangle to be invalidated and then calls Control.Invalidate(Rectangle) method. This method can be called multiple times consecutively. Windows creates a clip region and sends WM_PAINT message. Inside of the painting routine all changes will be effective only for the required area. When you click somewhere in the grid, it changes selection or focused rows and therefore can call Row.Invalidate() for different rows. When the next WM_PAINT message is dispatched to grid, the clip region will combine surfaces of multiple rows. That’s why you see changes.

    To resolve your problem, you should indicate what part of the row needs to be repainted. The best way to do it - send a NotifyPropertyChanged notification with empty or null field. In this case the grid will repaint the entire row. Or you can send multiple NotifyPropertyChanged() with affected fields. Note, if you use BindingList and send notifications with non-existing properties, you can have performance issue. Use the ThreadSafeBindingList instead. Get more details here:

    Best regards,


  • dx2003

    Thank you!

    You have made the best grid for real-time applications!



  • Dapfor Team

    We are very grateful for your appreciation of our product. Thank you.


Please sign in to leave a comment.

Powered by Zendesk