rrubio
15 years agoContributor
unable to pass an input parameter to a Web Service (object : array of strings)
Hi all,
I need to pass to a web service an input parameter whose type is Object, made of a array of strings.
TestComplete detects it when the webservice has been defined. However I am not able to success in the call to this webservice method.
I have attached the webservice definition as in TestComplete (file: webservicedefinition.jpg)
In my script I have this:
myobject=CreateVariantArray2(0,1)
myobject(0)="ORDCON_G"
Call WebServices.screen.GetList(Project.Variables.idSesion, -1, myobject, null, -1, null, listaXML)
It does return the following error:
SOAP-ENV:Client
Badly formed SOAP Message
ERROR #6254: Tag expected, XML input, ORDCON_G, is not in proper format as child of pobjScreenCodeList (ending at line 2 character 330).
Unit: "tmpRaul" Line: 24 Column: 5.<SOAP-ENV:Fault
xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/">
<faultcode>SOAP-ENV:Client</faultcode>
<faultstring>Badly
formed SOAP Message</faultstring>
<detail>
<error
xmlns="http://tempuri.org">
<text>ERROR #6254: Tag expected, XML
input, ORDCON_G, is not in proper format as child of pobjScreenCodeList (ending
at line 2 character 330).</text>
</error>
</detail>
</SOAP-ENV:Fault>
Unit: "tmpRaul"
Line: 24 Column: 5.
---------------------
could anybody explain how could I pass an array of strings?
the problem could be I am passing an array of variants and this is not understood by the server?
Regards,
Raul
I need to pass to a web service an input parameter whose type is Object, made of a array of strings.
TestComplete detects it when the webservice has been defined. However I am not able to success in the call to this webservice method.
I have attached the webservice definition as in TestComplete (file: webservicedefinition.jpg)
In my script I have this:
myobject=CreateVariantArray2(0,1)
myobject(0)="ORDCON_G"
Call WebServices.screen.GetList(Project.Variables.idSesion, -1, myobject, null, -1, null, listaXML)
It does return the following error:
SOAP-ENV:Client
Badly formed SOAP Message
ERROR #6254: Tag expected, XML input, ORDCON_G, is not in proper format as child of pobjScreenCodeList (ending at line 2 character 330).
Unit: "tmpRaul" Line: 24 Column: 5.<SOAP-ENV:Fault
xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/">
<faultcode>SOAP-ENV:Client</faultcode>
<faultstring>Badly
formed SOAP Message</faultstring>
<detail>
<error
xmlns="http://tempuri.org">
<text>ERROR #6254: Tag expected, XML
input, ORDCON_G, is not in proper format as child of pobjScreenCodeList (ending
at line 2 character 330).</text>
</error>
</detail>
</SOAP-ENV:Fault>
Unit: "tmpRaul"
Line: 24 Column: 5.
---------------------
could anybody explain how could I pass an array of strings?
the problem could be I am passing an array of variants and this is not understood by the server?
Regards,
Raul