Still celebrating National IT Professionals Day with 3 months of free Premium Membership. Use Code ITDAY17

x
?
Solved

Faster Draw/Refresh in PictureBox

Posted on 1997-04-16
2
Medium Priority
?
1,012 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
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
2 Comments
 
LVL 7

Accepted Solution

by:
kamall earned 200 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

Enroll in September's Course of the Month

This month’s featured course covers 16 hours of training in installation, management, and deployment of VMware vSphere virtualization environments. It's free for Premium Members, Team Accounts, and Qualified Experts!

Question has a verified solution.

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

Have you ever wanted to restrict the users input in a textbox to numbers, and while doing that make sure that they can't 'cheat' by pasting in non-numeric text? Of course you can do that with code you write yourself but it's tedious and error-prone …
If you have ever used Microsoft Word then you know that it has a good spell checker and it may have occurred to you that the ability to check spelling might be a nice piece of functionality to add to certain applications of yours. Well the code that…
Get people started with the process of using Access VBA to control Outlook using automation, Microsoft Access can control other applications. An example is the ability to programmatically talk to Microsoft Outlook. Using automation, an Access applic…
Show developers how to use a criteria form to limit the data that appears on an Access report. It is a common requirement that users can specify the criteria for a report at runtime. The easiest way to accomplish this is using a criteria form that a…
Suggested Courses

721 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