Click here to Skip to main content
Click here to Skip to main content

Flicker free MSChart

By , 4 Oct 2003
Rate this:
Please Sign up or sign in to vote.

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!! <!------------------------------- That's it! --------------------------->

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
No Biography provided

Comments and Discussions

 
-- There are no messages in this forum --
| Advertise | Privacy | Mobile
Web02 | 2.8.140415.2 | Last Updated 5 Oct 2003
Article Copyright 2003 by ShabuKC
Everything else Copyright © CodeProject, 1999-2014
Terms of Use
Layout: fixed | fluid