Classic ASP to WCF using the Service Moniker

Posted by Jab on Stack Overflow See other posts from Stack Overflow or by Jab
Published on 2009-09-18T18:29:03Z Indexed on 2010/03/25 7:03 UTC
Read the original article Hit count: 444

I am trying to consume a WCF logging service from classic ASP without deploy a Com wrapper. I found a method of doing so here. Here is the vb script, simplified.

Dim addr
addr = "service:mexAddress=""net.pipe://localhost/Services/Logging/LoggingManager/Mex""," _
& "address=""net.pipe://localhost/Services/Logging/LoggingManager/classic/""," _
& "contract=""ILoggingManagerClassic"", contractNamespace=""http://Services.Logging.Classic/""," _
& "binding=""NetNamedPipeBinding_ILoggingManagerClassic"", bindingNamespace=""http://Services.Logging.Classic/"""

set objErrorLogger = GetObject(addr)
Dim strError : strError = objErrorLogger.LogError("blahblah")

This works on Server 2008, but fails with this error on Server 2003.

Failed to do mex retrieval:Metadata contains a reference that cannot be resolved: net.pipe://localhost/Services/Logging/LoggingManager/Mex..

Only when running through ASP does it fail, a sample VBS file on the same machine using the same code works fine.

I think it may be permission related, but don't know where to begin. Anyone have any ideas?

EDIT - let me clarify that the WCF host is a windows service running as NETWORK SERVICE.

If this belongs on server fault, a moderator can move it. I have an account there as well.

© Stack Overflow or respective owner

Related posts about windows-server-2003

Related posts about asp-classic