Consuming SOAP Web Services
Ok I have a web service that I'm trying to consume in CF9. I'm able to hit the wsdl with SOAPUI and see the results. The results come back in XML format. It basically shows a list of rooms we use as meetings and show the times they are reserved. Here's the CF code I've written for it:
<cfinvoke
webservice="http://dwc-dreiman-w7e/WSExchangeMeetingRooms/exchange.asmx?WSDL"
method="FindResourceDetailForDay"
returnvariable="FindResourceDetailForDayResponse">
<cfinvokeargument name="c" value="Deerwood">
<cfinvokeargument name="d" value="">
</cfinvoke>
<cfoutput>Test value returns #FindResourceDetailForDayResponse#</cfoutput>
However that code returns this: Test value returns org.tempuri.FindResourceDetailForDayResponseFindResourceDetailForDayResult@13d9efc
The information that SoapUI returns in XML format is this:
<diffgr:diffgram xmlns:msdata="urn:schemas-microsoft-com:xml-msdata" xmlns:diffgr="urn:schemas-microsoft-com:xml-diffgram-v1">
<calendar xmlns="">
<Dwc-Room-02 diffgr:id="Dwc-Room-021" msdata:rowOrder="0" diffgr:hasChanges="inserted">
<StartTime>10/6/2010 11:00:00 AM</StartTime>
<EndTime>10/6/2010 12:00:00 PM</EndTime>
<BusyType>Busy</BusyType>
<Subject>Construction Meeting</Subject>
<Location/>
<IsException>False</IsException>
<IsMeeting>False</IsMeeting>
<IsPrivate>False</IsPrivate>
<IsRecurring>False</IsRecurring>
</Dwc-Room-02>
<Dwc-Room-01 diffgr:id="Dwc-Room-011" msdata:rowOrder="0" diffgr:hasChanges="inserted">
<StartTime>10/6/2010 9:00:00 AM</StartTime>
<EndTime>10/6/2010 11:00:00 AM</EndTime>
<BusyType>Busy</BusyType>
<Subject>Leadership Meeting</Subject>
<Location/>
<IsException>False</IsException>
<IsMeeting>False</IsMeeting>
<IsPrivate>False</IsPrivate>
<IsRecurring>False</IsRecurring>
</Dwc-Room-01>
<Dwc-Room-01 diffgr:id="Dwc-Room-012" msdata:rowOrder="1" diffgr:hasChanges="inserted">
<StartTime>10/6/2010 12:00:00 PM</StartTime>
<EndTime>10/6/2010 2:00:00 PM</EndTime>
<BusyType>Busy</BusyType>
<Subject>Strategic Conversation</Subject>
<Location/>
<IsException>False</IsException>
<IsMeeting>False</IsMeeting>
<IsPrivate>False</IsPrivate>
<IsRecurring>False</IsRecurring>
</Dwc-Room-01>
<Dwc-Room-01 diffgr:id="Dwc-Room-013" msdata:rowOrder="2" diffgr:hasChanges="inserted">
<StartTime>10/6/2010 2:00:00 PM</StartTime>
<EndTime>10/6/2010 3:00:00 PM</EndTime>
<BusyType>Busy</BusyType>
<Subject>Board Meeting</Subject>
<Location/>
<IsException>False</IsException>
<IsMeeting>False</IsMeeting>
<IsPrivate>False</IsPrivate>
<IsRecurring>False</IsRecurring>
</Dwc-Room-01>
</calendar>
</diffgr:diffgram>
How do I go about accessing the information within the parent/child nodes of the XML? This is my first time working with complex webservices in Coldfusion.
