J
JD
Can someone explain why HTTP Post fails when implementing this simple
webmethod?
[WebMethod]
public XmlNode Echo(XmlNode doc) {
return doc;
}
while the following works fine:
[WebMethod]
public XmlNode EchoDoc(string doc)
{
XmlDocument xmldoc = new XmlDocument();
xmldoc.LoadXml(doc);
return (XmlNode) xmldoc;
}
Configuration:
ASP.NET 1.1 and
<add name="HttpPost"/> has been added to the web.config
Here's the error I receive:
System.InvalidOperationException: Echo Web Service method name is not valid.
at System.Web.Services.Protocols.HttpServerProtocol.Initialize()
at System.Web.Services.Protocols.ServerProtocol.SetContext(Type type,
HttpContext context, HttpRequest request, HttpResponse response)
at System.Web.Services.Protocols.ServerProtocolFactory.Create(Type type,
HttpContext context, HttpRequest request, HttpResponse response, Boolean&
abortProcessing)
webmethod?
[WebMethod]
public XmlNode Echo(XmlNode doc) {
return doc;
}
while the following works fine:
[WebMethod]
public XmlNode EchoDoc(string doc)
{
XmlDocument xmldoc = new XmlDocument();
xmldoc.LoadXml(doc);
return (XmlNode) xmldoc;
}
Configuration:
ASP.NET 1.1 and
<add name="HttpPost"/> has been added to the web.config
Here's the error I receive:
System.InvalidOperationException: Echo Web Service method name is not valid.
at System.Web.Services.Protocols.HttpServerProtocol.Initialize()
at System.Web.Services.Protocols.ServerProtocol.SetContext(Type type,
HttpContext context, HttpRequest request, HttpResponse response)
at System.Web.Services.Protocols.ServerProtocolFactory.Create(Type type,
HttpContext context, HttpRequest request, HttpResponse response, Boolean&
abortProcessing)