Solved

Faster Draw/Refresh in PictureBox

Posted on 1997-04-16
2
983 Views
Last Modified: 2006-11-17
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?
0
Comment
Question by:sujevs
2 Comments
 
LVL 7

Accepted Solution

by:
kamall earned 100 total points
ID: 1425400
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
 

Author Comment

by:sujevs
ID: 1425401
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

Featured Post

Free Tool: SSL Checker

Scans your site and returns information about your SSL implementation and certificate. Helpful for debugging and validating your SSL configuration.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Most everyone who has done any programming in VB6 knows that you can do something in code like Debug.Print MyVar and that when the program runs from the IDE, the value of MyVar will be displayed in the Immediate Window. Less well known is Debug.Asse…
Background What I'm presenting in this article is the result of 2 conditions in my work area: We have a SQL Server production environment but no development or test environment; andWe have an MS Access front end using tables in SQL Server but we a…
Get people started with the process of using Access VBA to control Excel using automation, Microsoft Access can control other applications. An example is the ability to programmatically talk to Excel. Using automation, an Access application can laun…
Get people started with the utilization of class modules. Class modules can be a powerful tool in Microsoft Access. They allow you to create self-contained objects that encapsulate functionality. They can easily hide the complexity of a process from…

730 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question