Solved

VBScript to run Batch File

Posted on 2008-10-23
3
552 Views
Last Modified: 2008-10-23
How can I create a VB Script to run a batch file located in the following path:

C:\Test Directory\test.bat.
0
Comment
Question by:georgedschneider
  • 2
3 Comments
 
LVL 18

Accepted Solution

by:
exx1976 earned 500 total points
ID: 22787146
Set oShell = CreateObject("Wscript.Shell")
oShell.Run("""c:\test directory\test.bat""")

0
 

Author Comment

by:georgedschneider
ID: 22787350
That worked perfectly.  Is there anyway to hide or minimize the batch script display?

Is there a way to minimize or hide the batch script?
0
 
LVL 18

Assisted Solution

by:exx1976
exx1976 earned 500 total points
ID: 22787383
All the parameters for the run method can be found here:


http://msdn.microsoft.com/en-us/library/d5fk67ky(VS.85).aspx

There's like a dozen different options for window display.
0

Featured Post

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

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

Suggested Solutions

Title # Comments Views Activity
how to add field in my script 2 31
Scrollbar on an excel page 4 29
Can we place a tooltip on the actual vb6 form 5 35
Problem to open text file 11 68
Hello again, all.  For those of you that have been following along, you'll know that this is my third article on this topic (though it is not Part III).  This article is sort of remedial, and probably the topic with which I should have started the s…
When it comes to writing scripts for a Client/Server computing environment it is essential to consider some way of enabling the authentication functionality within a script. This sort of consideration mainly comes into the picture when we are dealin…
Here's a very brief overview of the methods PRTG Network Monitor (https://www.paessler.com/prtg) offers for monitoring bandwidth, to help you decide which methods you´d like to investigate in more detail.  The methods are covered in more detail in o…
I designed this idea while studying technology in the classroom.  This is a semester long project.  Students are asked to take photographs on a specific topic which they find meaningful, it can be a place or situation such as travel or homelessness.…

914 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

Need Help in Real-Time?

Connect with top rated Experts

12 Experts available now in Live!

Get 1:1 Help Now