Question

I have to ask that do we need to run

pipeline.Commands.AddScript(@"Import-Module 'C:\Program Files\Common Files\Microsoft Lync Server 2010\Modules\Lync\Lync.psd1'");

each time we run a Lync Powershell Cmdlet or is there any way we can do it while initializing Runspace? As we do in Exchange server case e.g.

RunspaceConfiguration.AddPSSnapIn("Microsoft.Exchange.Management.PowerShell.E2010", out warning);

And also what assembly references we need to add in C# project for Lync Server Powershell cmdlets (besides System.Management.Automation.Runspaces)

Thanks in advance.

Was it helpful?

Solution

Luckily I found the solution. And I posted it here.

Calling lync server cmdlets from c# .NET

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top