RunSpace04 (VB.NET) Code Sample

 

Here is the VB.NET source code for the Runspace04 sample. This sample uses the RunspaceInvoke class to execute a script that generates a terminating error. The host application is responsible for catching the error and interpreting the error record.

System_CAPS_noteNote

You can download the VB.NET source file (runspace02.vb) for this sample by using the Windows Software Development Kit for Windows Vista and Microsoft .NET Framework 3.0 Runtime Components. For download instructions, see How to Install Windows PowerShell and Download the Windows PowerShell SDK [delete].

The downloaded source files are available in the <PowerShell Samples> directory.

Show: