Visual C++ 7.1Visual C++ 7.0Windows 2003Windows 2000Visual C++ 6.0MFCIntermediateDevVisual StudioWindowsC++
Flicker free MSChart






1.16/5 (20 votes)
Oct 5, 2003

52070
A simple way to stop Flickering in MSChart.
Introduction
This solves the problem of Flickering while the Chart values are updated rapidly.
Using the code
The trick is to set the mschart property DrawMode to 1 as shown in the picture. We need to do one more thing, set the Redraw to false just before updating the chat values and set ReDraw to true and also GetUpdated region and Invalidate the updated region.
<CODE> m_ChartControl.SetRedraw(false) ; //.........code to update the Chart goes here //......................... CRgn rgn; m_ChartControl.GetUpdateRgn(&rgn); m_ChartControl.SetRedraw(true); m_ChartControl.InvalidateRgn(&rgn,false) ;
Points of Interest
Hope this helps for all those you looking for non-flickering charts.
History
None as of now!!
Thanks!!
Happy codeing!!!