Controlling Refresh/Paint - General Q

After updating a grid control, I'm having difficulty hiding the repaint (sic) visual effect. If I implement .SuspendLayout() on the control and .ResumeLayout() it appears to help but not much....

3 Replies

CB Clay Burch Syncfusion Team July 18, 2002 09:47 AM UTC

Try calling gridControl.BeginUpdate prior to your updates, and then GridControl1.EndUpdate after your updates to see if this helps.


SH Sam Horton July 22, 2002 01:45 PM UTC

> Try calling gridControl.BeginUpdate prior to your updates, and then GridControl1.EndUpdate after your updates to see if this helps. Perfect! Thank you, Clay!!


SH Sam Horton July 22, 2002 01:58 PM UTC

> Try calling gridControl.BeginUpdate prior to your updates, and then GridControl1.EndUpdate after your updates to see if this helps. FWIW, here's what I have in total.... When applying formats only this sequence seems to work best: gridControl.BeginUpdate() . . [change formats] . . gridConrolRefresh() gridControl.EndUpdate() When the entire grid is repopulated with new data, column names, orders and formats, this sequence works quite well: gridControl.BeginUpdate() gridControl.ReadOnly = False gridControl.Cols.RestoreFrozen() gridControl.ColCount = 0 gridControl.RowCount = 0 gridControl.UpdateScrollBars() . . [apply all new data/headers/formats] . . gridConrolRefresh() gridControl.EndUpdate() Very snappy. Nice control. :>

Loader.
Up arrow icon