VBscript

Silently launch scripts or applications with Hidden.vbs

Do you ever need to launch a process silently? Well you can easily accomplish this task by using Hidden.vbs! You no longer need to hardcode any process related info in your script because you can provide the path in the arguments.

Examples:
Hidden.vbs Powershell.exe -ExecutionPolicy Unrestricted -File C:\IT\PowerShell\PDF_Fix.ps1
Hidden.vbs Install.bat


Download The Script Now!

' //***************************************************************************
' // ***** Script Header *****
' // =======================================================
' // Silently launch a process
' // =======================================================
' //
' // File:      Hidden.vbs
' //
' // Purpose:   To provide a method of launching applications silently
' //
' //
' // ***** End Header *****
' //***************************************************************************

Set objShell = CreateObject("Shell.Application")
Set objWshShell = WScript.CreateObject("WScript.Shell")
Set objArgs = Wscript.Arguments

If (WScript.Arguments.Count >= 1) Then
    strFlag = WScript.Arguments(0)
    If (strFlag = "") OR (strFlag="help") OR (strFlag="/h") OR (strFlag="\h") OR (strFlag="-h") _
        OR (strFlag = "\?") OR (strFlag = "/?") OR (strFlag = "-?") OR (strFlag="h") _
        OR (strFlag = "?") Then
		DisplayUsage
        WScript.Quit
    Else
	ReDim args(WScript.Arguments.Count-1)
	For i = 0 To WScript.Arguments.Count-1
	  If InStr(WScript.Arguments(i), " ") > 0 Then
		args(i) = Chr(34) & WScript.Arguments(i) & Chr(34)
	  Else
		args(i) = WScript.Arguments(i)
	  End If
	Next

	objWshShell.Run Join(args, " "),0	
    End If
Else
    DisplayUsage
    WScript.Quit
End If

Sub DisplayUsage

    WScript.Echo "Silently launch a process" & vbCrLf & _
                 "" & vbCrLf & _
                 "Purpose:" & vbCrLf & _
                 "------------" & vbCrLf & _
                 "To provide a method of launching applications silently" & vbCrLf & _
                 "" & vbCrLf & _
                 "Usage:   " & vbCrLf & _
                 "--------" & vbCrLf & _				 
                 "" & vbCrLf & _
                 "hidden.vbs application <arguments>" & vbCrLf & _
                 "" & vbCrLf & _
                 "" & vbCrLf & _
                 "Sample usage:" & vbCrLf & _
                 "-------------------" & vbCrLf & _				 
                 "" & vbCrLf & _
                 "Hidden.vbs Powershell.exe -ExecutionPolicy Unrestricted -File C:\IT\PowerShell\PDF_Fix.ps1" & vbCrLf & _
                 "" & vbCrLf & _
                 "Hidden.vbs Install.bat" & vbCrLf & _
                 "" & vbCrLf & _
                 "" & vbCrLf

End Sub

Launch a hidden Powershell script


This short VBscript will launch a hidden Powershell script without any windows:

command = "powershell.exe -nologo -ExecutionPolicy Unrestricted -File C:\script.ps1"

set shell = CreateObject("WScript.Shell")

shell.Run command,0

Bitlocker Loop Fix

The following script will fix the Bitlocker Recovery Loop that prompts you for your Bitlocker password when you boot up your computer. This script is specifically for Windows 7 computers. Windows 8.1 and above have a much easier way to deal with this. You can find the Windows 8.1 method at the very bottom of this post.
Read more

Printer Install Tool

In my current job, we occasionally have a few large hiring classes through out the year. To make it easier for the new hires, I decided to make a Printer Install Tool which will allow anyone to install any of the printers on the floor. This way I am not being requested for a simple task like this. Follow the steps included in this post and you will be able to do the same!

Read more