ProcessStartInfo Constructor (String, String) (System.Diagnostics)

Switch View :
ScriptFree
.NET Framework Class Library
ProcessStartInfo Constructor (String, String)

Initializes a new instance of the ProcessStartInfo class, specifies an application file name with which to start the process, and specifies a set of command-line arguments to pass to the application.

Namespace:  System.Diagnostics
Assembly:  System (in System.dll)
Syntax

Visual Basic
Public Sub New ( _
	fileName As String, _
	arguments As String _
)
C#
public ProcessStartInfo(
	string fileName,
	string arguments
)
Visual C++
public:
ProcessStartInfo(
	String^ fileName, 
	String^ arguments
)
F#
new : 
        fileName:string * 
        arguments:string -> ProcessStartInfo

Parameters

fileName
Type: System.String
An application with which to start a process.
arguments
Type: System.String
Command-line arguments to pass to the application when the process starts.
Remarks

The file name is any application or document. In this case, a document is defined to be any file type that has an open or default action associated with it. You can view registered file types and their associated applications for your computer by using the Folder Options dialog box, which is available through the operating system. The Advanced button leads to a dialog box that shows whether there is an open action associated with a specific registered file type.

You can change the FileName or Arguments properties after you call this constructor, up to the time that the process starts. After you start the process, changing these values has no effect.

Version Information

.NET Framework

Supported in: 4, 3.5, 3.0, 2.0, 1.1, 1.0

.NET Framework Client Profile

Supported in: 4, 3.5 SP1
.NET Framework Security

Platforms

Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows XP SP2 x64 Edition, Windows Server 2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or later), Windows Server 2003 SP2

The .NET Framework does not support all versions of every platform. For a list of the supported versions, see .NET Framework System Requirements.
See Also

Reference