Go Premium for a chance to win a PS4. Enter to Win

x
?
Solved

Solution for a vbs script how start a external program with lowest priority

Posted on 2009-03-31
1
Medium Priority
?
451 Views
Last Modified: 2012-05-06
I look for a vbs script how start a external program with low or lowest  priority.
0
Comment
Question by:ROMCHCH
1 Comment
 
LVL 38

Accepted Solution

by:
Shift-3 earned 750 total points
ID: 24032894
Here's the easy way.  

Paste the script below into a text file with a .vbs extension.  Customize the value of the strProgram variable on line 1 with the location of the program.  Running the script will launch the program with Low priority.  To launch it with the BelowNormal priority instead, replace /LOW with /BELOWNORMAL in line 2.

To change a running program's priority, see this article.


strProgram = "C:\Program Files\MyProgram\MyProgram.exe"
strCommand = "cmd /c start """" /LOW """ & strProgram & """"
 
Set objShell = CreateObject("WScript.Shell")
objShell.Exec(strCommand)

Open in new window

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

This is an addendum to the following article: Acitve Directory based Outlook Signature (http://www.experts-exchange.com/Programming/Languages/Visual_Basic/VB_Script/Q_24950055.html) The script is fine, and works in normal client-server domains…
Introduction During my participation as a VBScript contributor at Experts Exchange, one of the most common questions I come across is this: "I have a script that runs against only one computer. How can I make it run against a list of computers in …
Integration Management Part 2
Is your data getting by on basic protection measures? In today’s climate of debilitating malware and ransomware—like WannaCry—that may not be enough. You need to establish more than basics, like a recovery plan that protects both data and endpoints.…
Suggested Courses

963 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