c# - Web Service error "Error in deserializing body of reply message for operation" -


i'm getting error below when trying call web service hp operations orchestration. appears wsdl not formatting response, or i'm not handling response. of things i've seen online refer message size being small. doesn't appear case. i've changed using var , doesn't help. ideas?

the call: var h = oosrclient.getflowrunhistorybyrunid(1);

the exception:

system.servicemodel.communicationexception caught   hresult=-2146233087   message=error in deserializing body of reply message operation 'getflowrunhistorybyrunid'.   source=mscorlib   stacktrace:     server stack trace:         @ system.servicemodel.dispatcher.xmlserializeroperationformatter.deserializebody(xmldictionaryreader reader, messageversion version, xmlserializer serializer, messagepartdescription returnpart, messagepartdescriptioncollection bodyparts, object[] parameters, boolean isrequest)        @ system.servicemodel.dispatcher.xmlserializeroperationformatter.deserializebody(xmldictionaryreader reader, messageversion version, string action, messagedescription messagedescription, object[] parameters, boolean isrequest)        @ system.servicemodel.dispatcher.operationformatter.deserializebodycontents(message message, object[] parameters, boolean isrequest)        @ system.servicemodel.dispatcher.operationformatter.deserializereply(message message, object[] parameters)        @ system.servicemodel.dispatcher.proxyoperationruntime.afterreply(proxyrpc& rpc)        @ system.servicemodel.channels.servicechannel.handlereply(proxyoperationruntime operation, proxyrpc& rpc)        @ system.servicemodel.channels.servicechannel.call(string action, boolean oneway, proxyoperationruntime operation, object[] ins, object[] outs, timespan timeout)        @ system.servicemodel.channels.servicechannelproxy.invokeservice(imethodcallmessage methodcall, proxyoperationruntime operation)        @ system.servicemodel.channels.servicechannelproxy.invoke(imessage message)     exception rethrown @ [0]:         @ system.runtime.remoting.proxies.realproxy.handlereturnmessage(imessage reqmsg, imessage retmsg)        @ system.runtime.remoting.proxies.realproxy.privateinvoke(messagedata& msgdata, int32 type)        @ testoo.oosr.wscentralservice.getflowrunhistorybyrunid(getflowrunhistorybyrunidrequest request)        @ testoo.oosr.wscentralserviceclient.testoo.oosr.wscentralservice.getflowrunhistorybyrunid(getflowrunhistorybyrunidrequest request) in c:\users\slippi3\documents\visual studio 2013\projects\testoo\testoo\service references\oosr\reference.cs:line 7526        @ testoo.oosr.wscentralserviceclient.getflowrunhistorybyrunid(int64 runid) in c:\users\slippi3\documents\visual studio 2013\projects\testoo\testoo\service references\oosr\reference.cs:line 7532        @ testoo.controllers.homecontroller.index() in c:\users\slippi3\documents\visual studio 2013\projects\testoo\testoo\controllers\homecontroller.cs:line 118   innerexception: system.invalidoperationexception        hresult=-2146233079        message=there error in xml document (1, 1287).        source=system.xml        stacktrace:             @ system.xml.serialization.xmlserializer.deserialize(xmlreader xmlreader, string encodingstyle, xmldeserializationevents events)             @ system.xml.serialization.xmlserializer.deserialize(xmlreader xmlreader, string encodingstyle)             @ system.servicemodel.dispatcher.xmlserializeroperationformatter.deserializebody(xmldictionaryreader reader, messageversion version, xmlserializer serializer, messagepartdescription returnpart, messagepartdescriptioncollection bodyparts, object[] parameters, boolean isrequest)        innerexception: system.invalidcastexception             hresult=-2147467262             message=cannot assign object of type system.object[] object of type testoo.oosr.wsrunhistorydetailsextend[].             source=ma3ir41a             stacktrace:                  @ microsoft.xml.serialization.generatedassembly.xmlserializationreaderwscentralservice.read90_item()                  @ microsoft.xml.serialization.generatedassembly.arrayofobjectserializer45.deserialize(xmlserializationreader reader)                  @ system.xml.serialization.xmlserializer.deserialize(xmlreader xmlreader, string encodingstyle, xmldeserializationevents events)             innerexception:  

here's response:

<?xml version="1.0" encoding="utf-8"?> <soapenv:envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:xsd="http://www.w3.org/2001/xmlschema" xmlns:xsi="http://www.w3.org/2001/xmlschema-instance"> <soapenv:body>     <ns1:getflowrunhistorybyrunidresponse soapenv:encodingstyle="http://schemas.xmlsoap.org/soap/encoding/" xmlns:ns1="http://wscentralservice.services.dharma.iconclude.com">  <getflowrunhistorybyrunidreturn soapenc:arraytype="xsd:anytype[1]" xsi:type="soapenc:array" xmlns:soapenc="http://schemas.xmlsoap.org/soap/encoding/"> <getflowrunhistorybyrunidreturn xsi:type="ns2:wsrunhistorydetailsextend" xmlns:ns2="http://iconclude.com/webservices/rss/v2.0/soap"> <uuid xsi:type="xsd:string">1111ac59-6bbe-47fa-841f-94e56c1b2111</uuid> <flowrevision xsi:type="xsd:string">4</flowrevision> <runhistoryid xsi:type="xsd:long">1</runhistoryid> <runname xsi:type="xsd:string"></runname> <userid xsi:type="xsd:string">aa\aaaaaaa</userid> <status xsi:type="xsd:string">resolved</status> <starttime xsi:type="xsd:long">1302621361380</starttime> <duration xsi:type="xsd:long">100</duration> <numsteps xsi:type="xsd:int">5</numsteps> <scheduledby xsi:type="xsd:string" xsi:nil="true"/> </getflowrunhistorybyrunidreturn> </getflowrunhistorybyrunidreturn> </ns1:getflowrunhistorybyrunidresponse> </soapenv:body> </soapenv:envelope> 

problems wsdl class generation , expected issue. building own classes handled it.


Comments

Popular posts from this blog

android - MPAndroidChart - How to add Annotations or images to the chart -

javascript - Add class to another page attribute using URL id - Jquery -

firefox - Where is 'webgl.osmesalib' parameter? -