
May 16th, 2001, 06:29 AM
|
|
Contributing User
|
|
Join Date: Dec 2002
Posts: 14,578
  
Time spent in forums: < 1 sec
Reputation Power: 22
|
|
|
I am getting error while sending paramter to SOAP(Web Method)
<i><b>Originally posted by : T.Sakthivel (sakthivel_t@hotmail.com)</b></i><br />Hi ,<br /><br /> We are creating web service using existing COM object which is written in Microsoft Visual Studio (Visual Basic). I have a problem <br /><br />while calling the method from ROPE.Proxy.(Simply I have a problem while sending the paramter to SOAP Server using ROPE client)<br /><br />The detailed information is as follows<br /><br /><br />To explain my problem, See the component which is created by me.<br /><br />I have a COM Component with Two methods<br /><br /> 1.) GetSOAPServerTime()<br /> 2.) Add(A,B)<br /><br /> If I am calling the GetSOAPServerTime method it is working fine.(Without parameter is working)<br /><br /> If I am calling the Add(A,B), it is giving error message as follows( That is if i am passing the parameter through ROPE, it is giving <br /><br />error message. Is there is any way to solve this. ( the error is as follows)<br /> <br /> If I am sending any parameters to SOAP Server it is raising the following error <br /> <br /> ****************************** ERROR **************************** <br /> Run-time error '-5000 (ffffec98)':<br /><br /> Error Executing Function Method: Add(aCallParams(0), aCallParams(1)) Add<br /><br /><br /><br /><br /><br />I have given my COM/SDL Files (generated by SDL Wizard) / VB Client Applicaion as follows<br /><br /><br /><br /><br />********************************************** COM **********************************************<br /><br /> Public Function GetSOAPServerTime()<br /> GetSOAPServerTime = Time()<br /> End Function<br /><br /> <br /> Public Function Add(intNum1 As Integer, intNum2 As Integer) As Integer<br /> Add = A + B<br /> End Function<br /><br /><br />***************************** SDL FILES GENERATED By SDL Wizard************************************<br /><br />My SDL Files which are generated by SDLWizard is as follows:-<br /><br /> 1.) clsSOAPTest.xml<br /> 2.) clsSOAPTest.asp<br /><br /> Those details are<br /><br />********************************************** clsSOAPTest.xml **********************************************<br /> <?xml version="1.0" ?> <br />- <!-- Generated 5/16/2001 2:30:19 PM by Microsoft SOAP Toolkit Wizard, Version 1.206.0 <br /> --> <br />- <serviceDescription xmlns:s0="http://tempuri.org/" name="SOAPTest" targetNamespace="http://tempuri.org/" <br /><br />xmlns="urn:schemas-xmlsoap-org:sdl.2000-01-25"><br />- <soap xmlns="urn:schemas-xmlsoap-org:soap-sdl-2000-01-25"><br />- <service><br />- <addresses><br /> <address uri="http://wks4/soaptest/clsSOAPTest.asp" /> <br /> </addresses><br />- <requestResponse name="GetSOAPServerTime" soapAction="http://tempuri.org/GetSOAPServerTime"><br /> <request ref="s0:GetSOAPServerTime" /> <br /> <response ref="s0:GetSOAPServerTimeResponse" /> <br /> </requestResponse><br />- <requestResponse name="Add" soapAction="http://tempuri.org/Add"><br /> <request ref="s0:Add" /> <br /> <response ref="s0:AddResponse" /> <br /> <parameterorder>intNum1 intNum2</parameterorder> <br /> </requestResponse><br /> </service><br /> </soap><br />- <schema targetNamespace="http://tempuri.org/" attributeFormDefault="qualified" elementFormDefault="qualified" <br /><br />xmlns="http://www.w3.org/1999/XMLSchema"><br /> <element name="GetSOAPServerTime" /> <br />- <element name="GetSOAPServerTimeResponse"><br />- <complexType><br />- <all><br /> <element name="result" xmlns:q1="http://www.w3.org/1999/XMLSchema" type="q1:string" /> <br /> </all><br /> </complexType><br /> </element><br />- <element name="Add"><br />- <complexType><br />- <all><br /> <element name="intNum1" xmlns:q2="http://www.w3.org/1999/XMLSchema" type="q2:short" /> <br /> <element name="intNum2" xmlns:q3="http://www.w3.org/1999/XMLSchema" type="q3:short" /> <br /> </all><br /> </complexType><br /> </element><br />- <element name="AddResponse"><br />- <complexType><br />- <all><br /> <element name="result" xmlns:q4="http://www.w3.org/1999/XMLSchema" type="q4:short" /> <br /> <element name="intNum1" xmlns:q5="http://www.w3.org/1999/XMLSchema" type="q5:short" /> <br /> <element name="intNum2" xmlns:q6="http://www.w3.org/1999/XMLSchema" type="q6:short" /> <br /> </all><br /> </complexType><br /> </element><br /> </schema><br /> </serviceDescription> <br /><br />********************************************** clsSOAPTest.asp **********************************************<br /><%@ Language=VBScript%><br /><br /><% Option Explicit<br /><br />Response.Expires = 0<br /><br />'--------------------------------------------<br />' SOAP ASP Interface file clsSOAPTest.asp<br />' Generated 5/16/2001 2:30:19 PM<br />' By Microsoft SOAP Toolkit Wizard, Version 1.206.0<br />'--------------------------------------------<br /><br />Const SOAP_SDLURI = "http://wks4/soaptest/clsSOAPTest.xml" 'URI of service description file<br />Const MSDNSOAP_SDL = "MSDNSOAP_clsSOAPTest" 'Application Variable name for caching SDL %><br /><!--#include file="listener.asp"--><br /><br /><%<br /><br />'_________________________________________________ ________________________________<br /><br />Public Function GetSOAPServerTime ()<br /> Dim objGetSOAPServerTime<br /> Set objGetSOAPServerTime = Server.CreateObject("SOAPTest.clsSOAPTest")<br /><br /> GetSOAPServerTime = objGetSOAPServerTime.GetSOAPServerTime()<br /> 'Insert additional code here<br /><br /><br /><br /> Set objGetSOAPServerTime = NOTHING<br />End Function<br /><br />'_________________________________________________ ________________________________<br /><br />Public Function Add (ByRef intNum1, ByRef intNum2)<br /> Dim objAdd<br /> Set objAdd = Server.CreateObject("SOAPTest.clsSOAPTest")<br /><br /> Add = objAdd.Add(intNum1, intNum2)<br /> 'Insert additional code here<br /><br /><br /><br /> Set objAdd = NOTHING<br />End Function<br /><br />'_________________________________________________ ________________________________<br /><br />%><br /><br /><br /> <br /><br />
|