For Programmers: Free Programming Magazines  


Home > Archive > Microsoft Webservices > April 2006 > Error 500 on oXmlHTTP.Send









You are viewing an archived Text-only version of the thread. To view this thread in it's original format and/or if you want to reply to this thread please [click here]

 

Author Error 500 on oXmlHTTP.Send
RG

2006-04-30, 8:10 am

I have an aspx web pages which interacts with an asmx service. The calls to
web service are done via Javascript.

The asmx service method has the following parameters:

public string RetrieveContact(string Id, int EntityTypeCode)


I am getting the following error when executing
oXmlHTTP.Send("id=" + sId + "&ObjectTypeCode=" + sObjectTypeCode);

which resolves into

oXmlHTTP.Send("id=7AA4FB86-24D6-DA11-B240-000F20F62526&ObjectTypeCode=1");



responseText "System.InvalidOperationException: Missing parameter:
EntityTypeCode.
at
System.Web.Services.Protocols.ValueCollectionParameterReader.Read(NameValueCollection
collection)
at System.Web.Services.Protocols.HtmlFormParameterReader.Read(HttpRequest
request)
at System.Web.Services.Protocols.HttpServerProtocol.ReadParameters()
at System.Web.Services.Protocols.WebServiceHandler.Invoke()
at System.Web.Services.Protocols.WebServiceHandler.CoreProcessRequest()
" String

Would anyone know how to resolve this.

Thanks in advance



RG

2006-04-30, 10:07 pm

I figured out the problem. The parameter name on the service didn't match
that on xmlhttp.send. Specifically, the second parameter.
"RG" <nobody@nowhere.com> wrote in message
news:eV4odWFbGHA.1020@TK2MSFTNGP02.phx.gbl...
>I have an aspx web pages which interacts with an asmx service. The calls
>to web service are done via Javascript.
>
> The asmx service method has the following parameters:
>
> public string RetrieveContact(string Id, int EntityTypeCode)
>
>
> I am getting the following error when executing
> oXmlHTTP.Send("id=" + sId + "&ObjectTypeCode=" + sObjectTypeCode);
>
> which resolves into
>
> oXmlHTTP.Send("id=7AA4FB86-24D6-DA11-B240-000F20F62526&ObjectTypeCode=1");
>
>
>
> responseText "System.InvalidOperationException: Missing parameter:
> EntityTypeCode.
> at
> System.Web.Services.Protocols.ValueCollectionParameterReader.Read(NameValueCollection
> collection)
> at
> System.Web.Services.Protocols.HtmlFormParameterReader.Read(HttpRequest
> request)
> at System.Web.Services.Protocols.HttpServerProtocol.ReadParameters()
> at System.Web.Services.Protocols.WebServiceHandler.Invoke()
> at System.Web.Services.Protocols.WebServiceHandler.CoreProcessRequest()
> " String
>
> Would anyone know how to resolve this.
>
> Thanks in advance
>
>
>



Sponsored Links







Also available: Server administration forum archive | Web Design forum archive | Software forum archive | Hardware reviews archive

Copyright 2008 codecomments.com