Forum Discussion

NisHera's avatar
NisHera
Valued Contributor
8 years ago

web service complex retrun values

I have a web service response like below

<soap:Body>
      <IsEmployee_TerminatedResponse xmlns="........../">
         <IsEmployee_TerminatedResult>
            <Key>0</Key>
            <Value>False</Value>
         </IsEmployee_TerminatedResult>
      </IsEmployee_TerminatedResponse>
   </soap:Body>

I can get Key or Value simply by using ...

function test(){
  var pqr = WebServices.MySoupService.IsEmployee_Terminated(15);
  Log.Message(pqr.Value)
} 

But how could I get values below response

   <soap:Body>
      <getContactPhoneResponse xmlns="......">
         <getContactPhoneResult>
            <Key>0</Key>
            <Value>Success</Value>
         </getContactPhoneResult>
         <list/>
      </getContactPhoneResponse>
   </soap:Body>

 can not do as below since there is a List Node also in response..

function test2(){
  var ABC = WebServices.MySoupService.getContactPhone(15);
  Log.Message(ABC.Value);
} 

any help appreciate...