I have problems referencing powershell functions from within Visual Studio 2008 or 2010. I have imported the
System.Management.Automation.dll but it still cannot find references to:
Dim connInfo As WSManConnectionInfo
Dim mycommand As PSCommand, pscmd As PowerShell
Dim ws As System.Management.Automation.Runspaces.run
Also it cannot find AuthenticationMechanism or RunspaceAvailability so I am unable to build the project
I tried removing and re-adding references with no luck.
I used to work ok before but it lost all the references for some reason. I even went back to an earlier version of the project.
I tried creating a new project with the appropriate references.
Are there different versions of System.Management.Automation.dll ?
Mine is 6.0.6000.16386 dated 12/01/2007