1

Possible Duplicate:
Run a completly hidden batch file

I have a bat file that open a window and show a lot of information, which bother me a lot. How could I run the bat file in background?

Hennes
  • 64,768
  • 7
  • 111
  • 168
Jichao
  • 7,145
  • 12
  • 52
  • 62

2 Answers2

3

There is a program called HStart (HiddenStart) which does it easily.

hstart /noconsole c:\example.bat

You can find hstart at ntwind.com Hidden Start Utility

barlop
  • 23,380
  • 43
  • 145
  • 225
2

Two ways to solve, depending on what you want, check the answers here:

Per @Twisty's request, here's a copy of the solution from this answer:

Set WshShell = CreateObject("WScript.Shell" ) 
WshShell.Run chr(34) & "C:\Batch Files\ mycommands.bat" & Chr(34), 0 
Set WshShell = Nothing 

Put this in a file with .vbs extension, edit the location to your bat file and run .vbs instead.

icyrock.com
  • 5,247
  • 2
  • 31
  • 30
  • As a highly valued Super User, I suggest you revisit this answer and [add more detail](http://meta.superuser.com/questions/5177/what-do-we-do-with-low-quality-answers-from-high-rep-users). Hyperlinks alone tend to point toward an answer without [actually being one](http://meta.stackexchange.com/questions/8231/are-answers-that-just-contain-links-elsewhere-really-good-answers/8259#8259). Please edit your answer so that it includes the essential elements from your linked source. – I say Reinstate Monica Apr 22 '17 at 15:40
  • @Twisty Sure, edited. – icyrock.com Apr 22 '17 at 21:34
  • You can't always relay on `WScript` to handle such cases. I have disabled mine for security reasons. – Деян Добромиров Jun 11 '20 at 06:40