Solved

How to get more CPU power for my VB6 program?

Posted on 2011-03-07
4
471 Views
Last Modified: 2012-05-11
Hi experts!

 I’m starting a VB6 program (exe) which write in memory via GDI. I’m interesting, what options I have to give it max. bigger priority as thread as I need bigger possible speed I can get . May be some API call which to notify Windows to give it more CPU power?

 Or may be I can do this setting manually in Windows ? The program work primary under Windows XP 32 bit, will be good but it is not a must to work in Win 7 too.

 Thanks.
0
Comment
Question by:dvplayltd
[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
4 Comments
 
LVL 11

Expert Comment

by:Plantwiz
ID: 35063158
You may change the process priorty in Windows 7 through Task Manager.

CTL+ALT+ESC to open task manager
Applications TAB
Select the Application
Right-click and "GO TO PROCESS"
then "SET Priority"
Set anywhere from Realtime-High-Above Normal-Normal-BelowNormal or Low
Confirm you wish to change priority



0
 
LVL 10

Accepted Solution

by:
LMiller7 earned 500 total points
ID: 35063199
Raising the priority of a process doesn't normally improve it's performance. If your VB6 program is the only CPU bound application running (the usual case) then it will already be receiving almost all the CPU time already. In this case raising it's priority will do nothing useful. If you do have more than one CPU bound application running then you need to deal with that situation.

The Windows API has the SetPriorityClass() function that will raise a processes priority. See MSDN for the details. But don't expect to gain anything by using it.
0
 
LVL 5

Expert Comment

by:BrianVSoft
ID: 35067201
Agree with LM7.. Process priority is rarely the problem if a program seems to be slow.. The problem is usually the way the program is written - or the sheer amount of data/processing it has to do..
There are many "pitfalls to avoid" and many "tricks of the trade" in writing efficient code.
You would probably need to give some details of the process before the guys could give some suggestions.
0
 

Author Closing Comment

by:dvplayltd
ID: 35067909
10x.
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

Can I legally transfer my OEM version of Windows to another PC?  (AKA - Can I put a new systemboard in my OEM PC?) Few of us are both IT and legal experts but we all have our own views of Microsoft's licensing rules and how they apply.  There are…
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…
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…
This lesson covers basic error handling code in Microsoft Excel using VBA. This is the first lesson in a 3-part series that uses code to loop through an Excel spreadsheet in VBA and then fix errors, taking advantage of error handling code. This l…

710 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