Sprog

ProcessStartInfo.StartSuspended Property

Definition

Gets or sets a value indicating whether the process should be started in a suspended state.

public:
 property bool StartSuspended { bool get(); void set(bool value); };
[System.Runtime.Versioning.SupportedOSPlatform("windows")]
[System.Runtime.Versioning.SupportedOSPlatform("macos")]
public bool StartSuspended { get; set; }
[<System.Runtime.Versioning.SupportedOSPlatform("windows")>]
[<System.Runtime.Versioning.SupportedOSPlatform("macos")>]
member this.StartSuspended : bool with get, set
Public Property StartSuspended As Boolean

Property Value

true if the process should be started suspended; otherwise, false. The default is false.

Attributes

Remarks

When this property is true, the process is created with its main thread suspended. The process doesn't begin execution until Resume() is called on the process handle, such as the handle returned by Start(ProcessStartInfo).

On Windows, the process is started with the CREATE_SUSPENDED flag.

On macOS, the process is started with the POSIX_SPAWN_START_SUSPENDED flag.

This property cannot be used together with UseShellExecute set to true.

Applies to