c# - How do I Create a RunspaceConnectionInfo object for PowerShell? -


i trying create runspace using

system.management.automation.runspaces.runspacefactory.createrunspace(runspaceconnectioninfo

but can't figure out how create runspaceconnectioninfo object. abstract , subclass find wsmanconnectioninfo object.

am supposed create own runspaceconnectioninfo subclass?

createrunspace static method. need invoke this:

ps d:\> $runspace = [system.management.automation.runspaces.runspacefactory]::createrunspace() ps d:\> $runspace   events                 : threadoptions          : default jobmanager             : runspaceconfiguration  : system.management.automation.runspaces.runspaceconfigforsingleshell initialsessionstate    : version                : 3.0 runspacestateinfo      : beforeopen runspaceavailability   : none connectioninfo         : originalconnectioninfo : languagemode           : apartmentstate         : unknown instanceid             : 49589d51-38db-4532-9914-0fd7f3306819 sessionstateproxy      : system.management.automation.runspaces.sessionstateproxy debugger               :    ps d:\> 

Comments

Popular posts from this blog

c# - DetailsView in ASP.Net - How to add another column on the side/add a control in each row? -

javascript - firefox memory leak -

Trying to import CSV file to a SQL Server database using asp.net and c# - can't find what I'm missing -