Private Sub Button1_Click(sender As Object, e As EventArgs) Handles Button1.Click Dim runspaceInvoke As RunspaceInvoke = New RunspaceInvoke() Dim printer As Object = runspaceInvoke.Invoke("Get-WmiObject Win32_Printer | Where-Object Name -eq ""CubePDF""") Dim v As PSObject = printer(0) Dim vv As Management.ManagementObject = v.ImmediateBaseObject vv.InvokeMethod("SetDefaultPrinter", Nothing) End Sub