Newbie here in Android and KSOAP2. I am trying to call a soap based web service but I am having difficulty passing the complex object in calling it.
My webservice requires the following complex input object. This schema represents my input and output messages.
<xsd:schema xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" targetNamespace="http://mycompany.com/ViewCustDetails" elementFormDefault="qualified">
<xsd:element name="ViewCustDetails">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="inputs" minOccurs="0">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="option" type="xsd:string" minOccurs="0"/>
<xsd:element name="variant" minOccurs="0">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="name" type="xsd:string" minOccurs="0" default="ACCT_ID"/>
<xsd:element name="value" type="xsd:string" minOccurs="0"/>
</xsd:sequence>
</xsd:complexType>
</xsd:element>
</xsd:sequence>
</xsd:complexType>
</xsd:element>
<xsd:element name="results" minOccurs="0">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="customerId" type="xsd:string" minOccurs="0"/>
<xsd:element name="customerName" type="xsd:string" minOccurs="0"/>
<xsd:element name="custClass" type="xsd:string" minOccurs="0"/>
</xsd:sequence>
</xsd:complexType>
</xsd:element>
</xsd:element>
</xsd:sequence>
</xsd:complexType>
</xsd:element>
</xsd:schema>
When requesting or calling the web service I need to populate the "inputs" element only. The "results" element can be neglected during outgoing call.
When the webservice returns, the "results" element are populated with what you have assigned and the elements are properly populated with the value.
I am just having difficulty on how to send the complex object in KSOAP 2 and retrieve the corresponding returned data. Most of the examples that I have found so far contains only simple objects and the schema is simple so I am struggling on how to solve this.
Any thoughts?