Click here to Skip to main content
Licence 
First Posted 4 Oct 2003
Views 40,267
Bookmarked 13 times

Flicker free MSChart

By | 4 Oct 2003 | Article
A simple way to stop Flickering in MSChart.

Setting the DrawMode to 1

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) ;
</CODE> 

Points of Interest

Hope this helps for all those you looking for non-flickering charts.

History

None as of now!!

Thanks!!

Happy codeing!!!

License

This article has no explicit license attached to it but may contain usage terms in the article text or the download files themselves. If in doubt please contact the author via the discussion board below.

A list of licenses authors might use can be found here

About the Author

ShabuKC

Web Developer

India India

Member



Sign Up to vote   Poor Excellent
Add a reason or comment to your vote: x
Votes of 3 or less require a comment

Comments and Discussions

 
You must Sign In to use this message board. (secure sign-in)
 
Search this forum  
 FAQ
    Noise  Layout  Per page   
  Refresh
-- There are no messages in this forum --
Permalink | Advertise | Privacy | Mobile
Web02 | 2.5.120517.1 | Last Updated 5 Oct 2003
Article Copyright 2003 by ShabuKC
Everything else Copyright © CodeProject, 1999-2012
Terms of Use
Layout: fixed | fluid