次の方法で共有


CommandInvocationIntrinsics.NewScriptBlock(String) Method

Definition

Compile a string into a script block.

public:
 System::Management::Automation::ScriptBlock ^ NewScriptBlock(System::String ^ scriptText);
public System.Management.Automation.ScriptBlock NewScriptBlock (string scriptText);
member this.NewScriptBlock : string -> System.Management.Automation.ScriptBlock
Public Function NewScriptBlock (scriptText As String) As ScriptBlock

Parameters

scriptText
String

The source text to compile.

Returns

The compiled script block.

Exceptions

Applies to