this is a rather obsolete library. you need to properly enable dcom on the remote server.
https://mvolo.com/connecting-to-iis-70-configuration-remotely-with-microsoftwebadministration/
a better approach is to use the IIS Rest API:
This browser is no longer supported.
Upgrade to Microsoft Edge to take advantage of the latest features, security updates, and technical support.
How do you use the ServerManager.OpenRemote("servername"). There is NO documentation on MSDN or any of the website on how it works. Microsoft Support Consultant is not able to assist and doesn't know either, where the support docs is.
Please help.
Did anyone at Microsoft ever got this correct and made it work.
I have research and nobody Online in any forum was able to ever make use of this method to get it actually working.
Please help anyone.
See my code below:
using (var iisManager = ServerManager.OpenRemote("serverNameHere"))
{
var appPool = iisManager.ApplicationPools[ApplicationPool];
```}
This code fails and iisManager is always null.
An object-oriented and type-safe programming language that has its roots in the C family of languages and includes support for component-oriented programming.
this is a rather obsolete library. you need to properly enable dcom on the remote server.
https://mvolo.com/connecting-to-iis-70-configuration-remotely-with-microsoftwebadministration/
a better approach is to use the IIS Rest API: