
Hide the command prompt windows
#16
Posted 23 August 2005 - 10:21 PM

#17
Posted 23 August 2005 - 10:45 PM

Set objWMIService = GetObject("winmgmts:" _
#18
Posted 24 August 2005 - 09:21 AM

An alternative would be to use "WScript.Shell" to create the processes instead of using WMI, as was indicated in the JScript example given earlier.
#19
Posted 16 March 2007 - 06:09 PM

What type of file should I save the script as, I am stilll learning all this stuf and not very good at it yet.
Apparently, you're better at this "stuff" than I am good sir! I say that because I failed in my attempt to get the advice to work. You were at least able to figure out what to modify in the sample script to achieve your desired results where as I was not. My vbs and js scripts seem to do "nothing." When I execute them, "nothing" seems to happen. That is to say, nothing launches and no errors are received.
Here are the contents of everything I have.
First... the bat file I wish to hide (so as to show you I'm not up to no good).
Thunderbird.bat (helps to launch multiple instances of Thunderbird so that I can use multiple profiles simultaneously)
@echo off set MOZ_NO_REMOTE=1 start thunderbird.exe -p set MOZ_NO_REMOTE=0
My attempts to hide the console window:
ThunderbirdLauncher.vbs
Const HIDDEN_WINDOW = 12 strComputer = "." Set objWMIService = GetObject("winmgmts:" _ & "{impersonationLevel=impersonate}!\\" & strComputer & "\root\cimv2") Set objStartup = objWMIService.Get("Win32_ProcessStartup") Set objConfig = objStartup.SpawnInstance_ objConfig.ShowWindow = HIDDEN_WINDOW Set objProcess = GetObject("winmgmts:root\cimv2:Win32_Process") errReturn = objProcess.Create("cmd.exe /c C:\Program Files\Mozilla Thunderbird 2\Thunderbird.bat", null, objConfig, intProcessID)
and lastly...
ThunderbirdLauncher.js
var WindowStyle_Hidden = 0 var objShell = WScript.CreateObject("WScript.Shell") var result = objShell.Run("cmd.exe /c C:\Program Files\Mozilla Thunderbird 2\Thunderbird.bat", WindowStyle_Hidden)
Thanks in advance for your help to those kind enough to reply. I apologize for my idiocy as this is the first time I've ever attached the extensions .vbs or .js to a file (i.e. I'm very, VERY green), although I have used batch files quite a bit in the past. As a side note, I've been reading through the forum a bit before registering, and I think I might call this place home. I'm no genius, but I do have a little I believe I can add here and there to make me valuable. If nothing else, I'll at least do my best to contribute.
Thanks again!
- Jace
#20
Posted 29 June 2011 - 10:04 PM

#21
Posted 04 September 2011 - 04:00 PM

ur r sir r stupid i used this code for minecraft server helphmm
and what are you exactly trying to create? a virus?
such things should not be encouraged on public forums...
an tyvm for this stuff like this can b used for many things y not put sumthing out there that ppl can look up instead for wiating for sumone to reply bak to them that could take up to 1-3 weeks( well) parts of this code ....
Edited by soul_shot_fire, 04 September 2011 - 04:01 PM.
#22
Posted 24 April 2013 - 05:45 AM

I have a bat file that copies some files from one directory to another it was working fine when it was not hidden but now it when i run it hidden it copies hose files to "C:/" please help me guys i want to copy those files where my bat file is.
Any reply would be so helpfull.
#23
Posted 24 April 2013 - 03:33 PM

Similar Topics
1 user(s) are reading this topic
0 members, 1 guests, 0 anonymous users
As Featured On:






