Mark
Mon Nov 22 18:26:59 CST 2004
This is a multi-part message in MIME format.
------=_NextPart_000_0018_01C4D0C9.3C5F02C0
Content-Type: text/plain;
charset="iso-8859-1"
Content-Transfer-Encoding: quoted-printable
No I meant using the Admin Base Objects (ABO). This is a COM interface =
exposed to C++.
See =
http://msdn.microsoft.com/library/default.asp?url=3D/library/en-us/iissdk=
/iis/ref_abo_adminbaseobjects.asp
- Mark
"Ben Strackany" <infoNOSPAM@developmentnow.nospam.com> wrote in =
message news:#wuu4eO0EHA.3692@TK2MSFTNGP14.phx.gbl...
Do you mean something like this?
Function GetSiteServerBindings(strServer, lngSiteNumber)
Set IISObj =3D getobject("IIS://" & strServer & "/W3SVC/" & =
lngSiteNumber)
GetSiteServerBindings =3D IISObj.ServerBindings(0)(0)
Set IISObj =3D nothing
end function
msgbox GetSiteServerBindings(".", "12345")
You can then use instrrev to find the last ":" & grab everything to =
the
right.
--=20
Ben Strackany
www.developmentnow.com
<a href=3D"
http://www.developmentnow.com">dn</a>
"Mark A. Richman" <nospam@nospam.com> wrote in message
news:Ovj2FlN0EHA.2540@TK2MSFTNGP09.phx.gbl...
> How can I read the ServerBindings for a given site using ABO? For =
example,
> "/LM/W3SVC/12345/" ???
>
> I need to parse out the ":80:myserver.com" to read the domain name =
for a
> given Site ID.
>
> - Mark
>
>
------=_NextPart_000_0018_01C4D0C9.3C5F02C0
Content-Type: text/html;
charset="iso-8859-1"
Content-Transfer-Encoding: quoted-printable
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML><HEAD>
<META http-equiv=3DContent-Type content=3D"text/html; =
charset=3Diso-8859-1">
<META content=3D"MSHTML 6.00.3790.218" name=3DGENERATOR>
<STYLE></STYLE>
</HEAD>
<BODY bgColor=3D#ffffff>
<DIV><FONT face=3DArial size=3D2>No I meant using the Admin Base Objects =
(ABO). This=20
is a COM interface exposed to C++.</FONT></DIV>
<DIV><FONT face=3DArial size=3D2></FONT> </DIV>
<DIV><FONT face=3DArial size=3D2>See <A=20
href=3D"
http://msdn.microsoft.com/library/default.asp?url=3D/library/en-u=
s/iissdk/iis/ref_abo_adminbaseobjects.asp">
http://msdn.microsoft.com/libr=
ary/default.asp?url=3D/library/en-us/iissdk/iis/ref_abo_adminbaseobjects.=
asp</A></FONT></DIV>
<DIV><FONT face=3DArial size=3D2></FONT> </DIV>
<DIV><FONT face=3DArial size=3D2>- Mark</FONT></DIV>
<DIV><FONT face=3DArial size=3D2></FONT> </DIV>
<BLOCKQUOTE=20
style=3D"PADDING-RIGHT: 0px; PADDING-LEFT: 5px; MARGIN-LEFT: 5px; =
BORDER-LEFT: #000000 2px solid; MARGIN-RIGHT: 0px">
<DIV>"Ben Strackany" <<A=20
=
href=3D"mailto:infoNOSPAM@developmentnow.nospam.com">infoNOSPAM@developme=
ntnow.nospam.com</A>>=20
wrote in message <A=20
=
href=3D"news:#wuu4eO0EHA.3692@TK2MSFTNGP14.phx.gbl">news:#wuu4eO0EHA.3692=
@TK2MSFTNGP14.phx.gbl</A>...</DIV>Do=20
you mean something like this?<BR><BR>Function =
GetSiteServerBindings(strServer,=20
lngSiteNumber)<BR> Set IISObj =3D getobject("IIS://" =
&=20
strServer & "/W3SVC/" & lngSiteNumber)<BR> =20
GetSiteServerBindings =3D =
IISObj.ServerBindings(0)(0)<BR> Set=20
IISObj =3D nothing<BR>end function<BR><BR>msgbox =
GetSiteServerBindings(".",=20
"12345")<BR><BR>You can then use instrrev to find the last ":" & =
grab=20
everything to the<BR>right.<BR><BR>-- <BR>Ben Strackany<BR><A=20
=
href=3D"
http://www.developmentnow.com">www.developmentnow.com</A><BR><BR>=
<a=20
href=3D"<A=20
=
href=3D'
http://www.developmentnow.com">dn</a'>http://www.developmentnow.c=
om">dn</a</A>><BR><BR><BR>"Mark=20
A. Richman" <<A =
href=3D"mailto:nospam@nospam.com">nospam@nospam.com</A>>=20
wrote in message<BR><A=20
=
href=3D"news:Ovj2FlN0EHA.2540@TK2MSFTNGP09.phx.gbl">news:Ovj2FlN0EHA.2540=
@TK2MSFTNGP09.phx.gbl</A>...<BR>>=20
How can I read the ServerBindings for a given site using ABO? For=20
example,<BR>> "/LM/W3SVC/12345/" ???<BR>><BR>> I need to =
parse out=20
the ":80:myserver.com" to read the domain name for a<BR>> given =
Site=20
ID.<BR>><BR>> - =
Mark<BR>><BR>><BR><BR></BLOCKQUOTE></BODY></HTML>
------=_NextPart_000_0018_01C4D0C9.3C5F02C0--