D
Datura
Hi, I'm trying to use a wdsl generated proxy class to Invoke a web services
method which outputs a soap envelope shown below.
The response I'm looking for has two parts, one is a "Result" node, which I
am successful in getting back, the other is the "vntReturn" node, which I
know is being sent, but the Invoke method is not returning.
The problem seems to be that the Invoke method simply is returning only one
value, that found in the "Return" node. The attempt to assign vntReturn
from results[1] gives a run-time error of array index out-of-bounds.
Here's the proxy class code:
[System.Web.Services.Protocols.SoapRpcMethodAttribute("http://tempuri.org/Da
vinci/action/Gateway.Perform",
RequestNamespace="http://tempuri.org/Davinci/message/",
ResponseNamespace="http://tempuri.org/Davinci/message/")]
[return: System.Xml.Serialization.SoapElementAttribute("Result")]
public string Perform(string vntReceive, string vntReturn) {
object[] results = this.Invoke("Perform", new object[] {
vntReceive,
vntReturn});
vntReturn = ((string)(results[1]));
/return ((string)(results[0]));
}
Any help or pointers greatly appreciated!
Thanks!
<SOAP-ENV:Body xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/"
SOAPENV:encodingStyle="http://schemas.xmlsoap.org/soap/encoding/">
<SOAPSDK4erformResponse
xmlns:SOAPSDK4="http://tempuri.org/Davinci/message/">
<Result>true</Result>
<vntReturn
xmlns:SOAPSDK2="http://www.w3.org/2001/XMLSchema-instance"
SOAPSDK2:type="SOAPSDK1:string">
<body>
<security_user_id><![CDATA[5]]></security_user_id>
<security_group_id><![CDATA[1]]></security_group_id>
<security_group_descr_short><![CDATA[MTG]]></security_group_d
escr_short>
<user_name><![CDATA[James Carmichael]]></user_name>
<user_logon><![CDATA[CARMICHAELJ]]></user_logon>
<error_level_id><![CDATA[2]]></error_level_id>
<mts_server_name><![CDATA[D01SVR84]]></mts_server_name>
<db_server_name><![CDATA[D01SVR82]]></db_server_name>
<db_name><![CDATA[rccl_qa]]></db_name>
<international_rep_ind><![CDATA[0]]></international_rep_ind&g
t;
<ir_country_code><![CDATA[]]></ir_country_code>
<session_id><![CDATA[{CB415EAD-7F2A-42E6-B715-C0F3FDE284B8}]]>&l
t;/session_id>
</body>
</vntReturn>
</SOAPSDK4erformResponse>
</SOAP-ENV:Body>
method which outputs a soap envelope shown below.
The response I'm looking for has two parts, one is a "Result" node, which I
am successful in getting back, the other is the "vntReturn" node, which I
know is being sent, but the Invoke method is not returning.
The problem seems to be that the Invoke method simply is returning only one
value, that found in the "Return" node. The attempt to assign vntReturn
from results[1] gives a run-time error of array index out-of-bounds.
Here's the proxy class code:
[System.Web.Services.Protocols.SoapRpcMethodAttribute("http://tempuri.org/Da
vinci/action/Gateway.Perform",
RequestNamespace="http://tempuri.org/Davinci/message/",
ResponseNamespace="http://tempuri.org/Davinci/message/")]
[return: System.Xml.Serialization.SoapElementAttribute("Result")]
public string Perform(string vntReceive, string vntReturn) {
object[] results = this.Invoke("Perform", new object[] {
vntReceive,
vntReturn});
vntReturn = ((string)(results[1]));
/return ((string)(results[0]));
}
Any help or pointers greatly appreciated!
Thanks!
<SOAP-ENV:Body xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/"
SOAPENV:encodingStyle="http://schemas.xmlsoap.org/soap/encoding/">
<SOAPSDK4erformResponse
xmlns:SOAPSDK4="http://tempuri.org/Davinci/message/">
<Result>true</Result>
<vntReturn
xmlns:SOAPSDK2="http://www.w3.org/2001/XMLSchema-instance"
SOAPSDK2:type="SOAPSDK1:string">
<body>
<security_user_id><![CDATA[5]]></security_user_id>
<security_group_id><![CDATA[1]]></security_group_id>
<security_group_descr_short><![CDATA[MTG]]></security_group_d
escr_short>
<user_name><![CDATA[James Carmichael]]></user_name>
<user_logon><![CDATA[CARMICHAELJ]]></user_logon>
<error_level_id><![CDATA[2]]></error_level_id>
<mts_server_name><![CDATA[D01SVR84]]></mts_server_name>
<db_server_name><![CDATA[D01SVR82]]></db_server_name>
<db_name><![CDATA[rccl_qa]]></db_name>
<international_rep_ind><![CDATA[0]]></international_rep_ind&g
t;
<ir_country_code><![CDATA[]]></ir_country_code>
<session_id><![CDATA[{CB415EAD-7F2A-42E6-B715-C0F3FDE284B8}]]>&l
t;/session_id>
</body>
</vntReturn>
</SOAPSDK4erformResponse>
</SOAP-ENV:Body>