Home All Groups Group Topic Archive Search About

Accessing information on IIS programatically

Author
18 Feb 2005 12:55 PM
thechaosengine
Hi all,

Does anyone know of a way I can get information on the status of IIS including
what websites and Virtual Roots are defined and whether they are running
or not.

I'll be using C# in particular and am currently looking into WMI - something
that I havent used in the past.

Anyone know if I'm on the right track?

Many thanks

Kindest Regards

Author
18 Feb 2005 3:12 PM
NuTcAsE
IIS 5.0 exposes a COM+ object model that you can interop with to
progrramatically access and modify the IIS metabase. Im not sure which
dll or what interfaces it exposes, may some one from MS can help there.
But if you are using IIS 6.0, WMI will definately work. IIS 6.0 exposes
a WMI namespace that you can connect to and manage the IIS metabase.
Sorry dont have more details on that for ya, but if your app is gonna
manage 5.0 or older WMI may not be possible. I could be wrong here
though.

Hope this helps,
NuTcAsE
Are all your drivers up to date? click for free checkup

Author
18 Feb 2005 4:20 PM
Patrice
Try :
http://msdn.microsoft.com/library/default.asp?url=/library/en-us/iissdk/html/d39fae66-abe7-4902-a3fc-f36151561f01.asp
(uses System.DirectoryServices) but you'll find also how to do thiw with WMI
or ADSI...

AFAIK the 2.0 should have a programming model to access the IIS metabase...

Patrice

--

Show quoteHide quote
"thechaosengine" <na> a écrit dans le message de
news:14809632443281536993424@news.microsoft.com...
> Hi all,
>
> Does anyone know of a way I can get information on the status of IIS
including
> what websites and Virtual Roots are defined and whether they are running
> or not.
>
> I'll be using C# in particular and am currently looking into WMI -
something
> that I havent used in the past.
>
> Anyone know if I'm on the right track?
>
> Many thanks
>
> Kindest Regards
>
>

Bookmark and Share