Faster Draw/Refresh in PictureBox

I use a PictureBox control to display a network, i.e. a BIG number of Lines, Circles and Text. Drawing/Refreshing is VERY SLOW. Are there any techniques to accelerate the process?

Have heard something about "drawing in memory" but don't know what it is and how it's working. Has it something to do with .hDC property?
sujevsAsked:
Who is Participating?
 
kamallConnect With a Mentor Commented:
To draw fast enough on a Picture object you must:

Either
Use a DoEvents (not Picture1.Refresh) after each line or circles is drawn,

Or
Dont use Refresh or DoEvents until you finish your drawing and then give a DoEvents. This is much faster than the first solution.

0
 
sujevsAuthor Commented:
The problem is that I don't use Refresh or DoEvents to update the picture, so the solution provided unfortunately does not help me a lot, though it could be valuable in the future for some other occations :)
0
All Courses

From novice to tech pro — start learning today.