Solved

How to get more CPU power for my VB6 program?

Posted on 2011-03-07
4
473 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

Industry Leaders: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

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

Sometimes people don't understand why download speed shows differently for Windows than Linux.Specially, this article covers and shows the solution for throughput difference for Windows than a Linux machine. For this, I arranged a test scenario.I…
Since upgrading to Office 2013 or higher installing the Smart Indenter addin will fail. This article will explain how to install it so it will work regardless of the Office version installed.
As developers, we are not limited to the functions provided by the VBA language. In addition, we can call the functions that are part of the Windows operating system. These functions are part of the Windows API (Application Programming Interface). U…
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…
Suggested Courses
Course of the Month10 days, 13 hours left to enroll

628 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