Answer the question
In order to leave comments, you need to log in
Are there ways to completely hide the PowerShell window while executing a task?
A task has been created in the scheduler that starts the execution of a PowerShell script for execution on an event. I use the following launch options to hide the console window
powershell.exe -windowStyle hidden -command ″C:\script.ps1″
Answer the question
In order to leave comments, you need to log in
command = "powershell.exe -nologo -command C:\path\to\your\ps\script.ps1"
set shell = CreateObject("WScript.Shell")
shell.Run command,0
is to put in vbs file, in scheduler jobs to specify the path to vbs.
It's better to tell me how to set the output of Ps to show since I don't see anything.
There is some powershell code in the script and the robocopy utility - I need to see the process, but it is not there by default. In general, everything starts in the background.
If you open PoSh and run a script in it, then the whole process is displayed.
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question