I'm trying to write a web services client using VB.NET (VS 2003) for a
PocketPC (using .Net Compact Framework 1.0 SP2) either on the emulator or my
device. Other services are working fine however when I try to call a service
that returns a complex object I get a "formatException". The exact same code
works perfectly using .NET Framework 1.0 on my PC. (Aren't the .Net
Framework and .NET Compact Framework the same?)
Unfortunately I don't have access to the server code (written in Java) so I
can't simplify the object to identify which part is causing the problem (see
below for the response I get back from the server) Is there any way to debug
the code that is processing the response? I found some autogenerated code in
VS which invokes the web service but not the code that actually reads the
service response.
Does anybody have any ideas as to how I can get this to work using the .Net
Compact Framework?
XML response from server
----------------------------
<?xml version='1.0' encoding='UTF-8'?>
<soap:Envelope xmlns:xsi='http://www.w3.org/2001/XMLSchema-instance'
xmlns:xsd='http://www.w3.org/2001/XMLSchema'
xmlns:soap='http://schemas.xmlsoap.org/soap/envelope/'
xmlns:soapenc='http://schemas.xmlsoap.org/soap/encoding/'
soap:encodingStyle='http://schemas.xmlsoap.org/soap/encoding/'
xmlns:ns5='http://www.themindelectric.com/package/com.hummingbird.hc.api/'>
<soap:Body>
<n:getLatestDocumentResponse
xmlns:n='http://tempuri.org/com.peopledoc.jura.soap.CollaborationService'>
<Result href='#id0'>
</Result>
</n:getLatestDocumentResponse>
<id0 id='id0' soapenc:root='0' xsi:type='ns5:Document'>
<id xsi:type='xsd:string'>2324</id>
<name xsi:type='xsd:string'>Bum.bmp</name>
<description xsi:type='xsd:string'>Bum.bmp</description>
<parent href='#id1'></parent>
<statusID xsi:type='xsd:string'>0</statusID>
<timetable href='#id2'></timetable>
<data xsi:nil='1'></data>
<latestVersionNumber xsi:type='xsd:int'>1</latestVersionNumber>
<checkedOutByUser xsi:nil='1'></checkedOutByUser>
<checkedOutByOrg xsi:nil='1'></checkedOutByOrg>
<isPlaceHolder xsi:type='xsd:boolean'>false</isPlaceHolder>
<writePermission xsi:type='xsd:boolean'>true</writePermission>
<deletePermission xsi:type='xsd:boolean'>true</deletePermission>
<reviewVersionablePermission
xsi:type='xsd:boolean'>false</reviewVersionablePermission>
<versions href='#id3'></versions>
</id0>
<id1 id='id1' soapenc:root='0' xsi:type='ns5:FolderRef'>
<id xsi:type='xsd:string'>1941</id>
<name xsi:type='xsd:string'>Girls</name>
</id1>
<id2 id='id2' soapenc:root='0' xsi:type='ns5:Timetable'>
<isCompleted xsi:type='xsd:boolean'>false</isCompleted>
<reminderFrequency xsi:type='xsd:int'>0</reminderFrequency>
<reminderPeriod xsi:type='xsd:int'>0</reminderPeriod>
<creationDate
xsi:type='xsd:dateTime'>2003-12-09T22:43:42.843Z</creationDate>
<dueDate xsi:nil='1'></dueDate>
<completionDate xsi:nil='1'></completionDate>
<completedByUsername xsi:type='xsd:string'></completedByUsername>
</id2>
<id3 id='id3' soapenc:root='0' xsi:type='soapenc:Array'
soapenc:arrayType='ns5:VersionSummary[1]'>
<i href='#id4'></i>
</id3>
<id4 id='id4' soapenc:root='0' xsi:type='ns5:VersionSummary'>
<versionNumber xsi:type='xsd:int'>1</versionNumber>
<comments xsi:type='xsd:string'></comments>
<timestamp
xsi:type='xsd:dateTime'>2003-12-09T22:43:42.859Z</timestamp>
</id4>
</soap:Body>
</soap:Envelope>