PowerShell Logo Small

Start-Process



This is the built-in help made by Microsoft for the command 'Start-Process', in PowerShell version 2 - as retrieved from Windows version 'Microsoft® Windows Vista™ Ultimate ' PowerShell help files on 2016-06-23.

For PowerShell version 3 and up, where you have Update-Help, this command was run just before creating the web pages from the help files.

SYNOPSIS

Starts one or more processes on the local computer.

SYNTAX


Start-Process [-FilePath] <string> [[-ArgumentList] <string[]>] [-Credential <PSCredential>] [-LoadUserProfile] [-NoNewWindow] [-PassThru] [-Redi
rectStandardError <string>] [-RedirectStandardInput <string>] [-RedirectStandardOutput <string>] [-UseNewEnvironment] [-Wait] [-WorkingDirectory
<string>] [<CommonParameters>]
Start-Process [-FilePath] <string> [[-ArgumentList] <string[]>] [-PassThru] [-Verb <string>] [-Wait] [-WindowStyle {Normal | Hidden | Minimized |
Maximized}] [-WorkingDirectory <string>] [<CommonParameters>]



Search powershellhelp.space

DESCRIPTION


Starts one or more processes on the local computer. To specify the program that runs in the process, enter an executable file or script file, or
a file that can be opened by using a program on the computer. If you specify a non-executable file, Start-Process starts the program that is ass
ociated with the file, much like the Invoke-Item cmdlet.

You can use the parameters of Start-Process to specify options, such as loading a user profile, starting the process in a new window, or using al
ternate credentials.



<

RELATED LINKS

Online version: http://go.microsoft.com/fwlink/?LinkID=135261
Start-Service
Get-Process
Stop-Process
Wait-Process
Debug-Process

REMARKS

<

Examples


-------------------------- EXAMPLE 1 --------------------------

C:\PS>start-process sort.exe



Description
-----------
This command starts a process that uses the Sort.exe file in the current directory. The command uses all of the default values, including the def
ault window style, working directory, and credentials.








-------------------------- EXAMPLE 2 --------------------------

C:\PS>start-process myfile.txt -workingdirectory "C:\PS-Test" -verb Print



Description
-----------
This command starts a process that prints the C:\PS-Test\MyFile.txt file.








-------------------------- EXAMPLE 3 --------------------------

C:\PS>start-process Sort.exe -RedirectStandardInput Testsort.txt -RedirectStandardOutput Sorted.txt -RedirectStandardError SortError.txt -UseNewE
nvironment



Description
-----------
This command starts a process that sorts items in the Testsort.txt file and returns the sorted items in the Sorted.txt files. Any errors are writ
ten to the SortError.txt file.

The UseNewEnvironment parameter specifies that the process runs with its own environment variables.








-------------------------- EXAMPLE 4 --------------------------

C:\PS>start-process notepad -wait -windowstyle Maximized



Description
-----------
This command starts the Notepad process. It maximizes the window and retains the window until the process completes.