Click here to Skip to main content
15,909,896 members
Home / Discussions / Web Development
   

Web Development

 
GeneralASP development help Pin
Its due when22-Nov-04 11:23
Its due when22-Nov-04 11:23 
GeneralRe: ASP development help Pin
John Parker23-Nov-04 5:34
John Parker23-Nov-04 5:34 
Questionsize? Pin
rgoyal21-Nov-04 23:28
rgoyal21-Nov-04 23:28 
AnswerRe: size? Pin
john3parker22-Nov-04 5:16
john3parker22-Nov-04 5:16 
GeneralRe: size? Pin
Anonymous24-Nov-04 1:01
Anonymous24-Nov-04 1:01 
GeneralCalendar control, with scroll on year basis Pin
gP_t_gr821-Nov-04 19:28
gP_t_gr821-Nov-04 19:28 
GeneralRe: Calendar control, with scroll on year basis Pin
John Parker23-Nov-04 5:46
John Parker23-Nov-04 5:46 
GeneralArray of Enumeration values deserialization problem Pin
john3parker21-Nov-04 18:43
john3parker21-Nov-04 18:43 
Hi,
I've got a .NET 1.1 C# client connecting to an Axis 1.1 web service. The service is sending SOAP XML as RPC/encoded and most everything deserializes correctly. The problem is with enumerations. Single enumerations deserialize just fine. Arrays with enumeration values do not deserialize correctly in the C# client. It always assigns the first enumeration value. Sadly, I wrote a Java client and it works just fine.

I used wsdl.exe to create the proxy class and everything looks fine within it. Perhaps there are additional settings to get .NET to consume an RPC/encoded web service?

As a test I created a .NET web service to return an array of enumerated values. It defaulted to Document/Literal style and the client was able to deserialize it just fine. I modified the web service to be RPC/encoded styling and again the client was able to deserialize.

The difference was how the web service generated the SOAP XML. The .NET RPC/encoded web service created its array of enumerated values like this:
- <soap:Body soap:encodingStyle="http://schemas.xmlsoap.org/soap/encoding/">
- <types:getEnumeratedResponse>
<getEnumeratedResult href="#id1" />
</types:getEnumeratedResponse>
- <soapenc:Array id="id1" soapenc:arrayType="types:EnumeratedCodeType[3]">
<Item xsi:type="types:EnumeratedCodeType">Green</Item>
<Item xsi:type="types:EnumerateddCodeType">Blue</Item>
<Item xsi:type="types:EnumeratedCodeType">Red</Item>
</soapenc:Array>
</soap:Body>

The Axis 1.1 RPC/encoded web service created its array of enumerated values like this:
- <soapenv:Body>
- <ns1:getEnumeratedResponse soapenv:encodingStyle="http://schemas.xmlsoap.org/soap/encoding/" xmlns:ns1="http://beangen.beanraw.samples">
- <getEnumeratedReturn xsi:type="soapenc:Array" soapenc:arrayType="ns2:EnumeratedCodeType[5]" xmlns:ns2="urn:om.beanraw.samples" xmlns:soapenc="http://schemas.xmlsoap.org/soap/encoding/">
<item href="#id0" />
<item href="#id1" />
<item href="#id2" />
<item href="#id3" />
<item href="#id4" />
</getEnumeratedReturn>
</ns1:getEnumeratedResponse>
<multiRef id="id4" soapenc:root="0" soapenv:encodingStyle="http://schemas.xmlsoap.org/soap/encoding/" xsi:type="ns3:EnumeratedCodeType" xmlns:soapenc="http://schemas.xmlsoap.org/soap/encoding/" xmlns:ns3="urn:om.beanraw.samples">Green</multiRef>
<multiRef id="id0" soapenc:root="0" soapenv:encodingStyle="http://schemas.xmlsoap.org/soap/encoding/" xsi:type="ns4:EnumeratedCodeType" xmlns:ns4="urn:om.beanraw.samples" xmlns:soapenc="http://schemas.xmlsoap.org/soap/encoding/">Red</multiRef>
<multiRef id="id3" soapenc:root="0" soapenv:encodingStyle="http://schemas.xmlsoap.org/soap/encoding/" xsi:type="ns5:EnumeratedCodeType" xmlns:ns5="urn:om.beanraw.samples" xmlns:soapenc="http://schemas.xmlsoap.org/soap/encoding/">Blue</multiRef>
<multiRef id="id2" soapenc:root="0" soapenv:encodingStyle="http://schemas.xmlsoap.org/soap/encoding/" xsi:type="ns6:EnumeratedCodeType" xmlns:ns6="urn:om.beanraw.samples" xmlns:soapenc="http://schemas.xmlsoap.org/soap/encoding/">Purple</multiRef>
<multiRef id="id1" soapenc:root="0" soapenv:encodingStyle="http://schemas.xmlsoap.org/soap/encoding/" xsi:type="ns7:EnumeratedCodeType" xmlns:ns7="urn:om.beanraw.samples" xmlns:soapenc="http://schemas.xmlsoap.org/soap/encoding/">Black</multiRef>
</soapenv:Body>

The differences are obvious. I'm not sure how to handle it correctly in .NET though. Any help with using Axis 1.1 web services with C#.NET would be appreciated!


-- John Parker

Questionhow to create text boxes dinamically in javascript??? Pin
gP_t_gr819-Nov-04 22:19
gP_t_gr819-Nov-04 22:19 
AnswerRe: how to create text boxes dinamically in javascript??? Pin
Om Prakash Pant19-Nov-04 23:24
Om Prakash Pant19-Nov-04 23:24 
QuestionHow to call &quot;Send page by email&quot; in javascript? Pin
davilism19-Nov-04 5:06
davilism19-Nov-04 5:06 
AnswerRe: How to call &quot;Send page by email&quot; in javascript? Pin
Om Prakash Pant19-Nov-04 23:26
Om Prakash Pant19-Nov-04 23:26 
GeneralJavaScript:Window.Open(...) Pin
Bassam Abdul-Baki18-Nov-04 2:06
professionalBassam Abdul-Baki18-Nov-04 2:06 
GeneralRe: javascriptWindow.Open(...) Pin
Om Prakash Pant19-Nov-04 23:29
Om Prakash Pant19-Nov-04 23:29 
GeneralRe: javascriptWindow.Open(...) Pin
Bassam Abdul-Baki20-Nov-04 6:11
professionalBassam Abdul-Baki20-Nov-04 6:11 
GeneralRe: javascriptWindow.Open(...) Pin
Anonymous21-Nov-04 19:09
Anonymous21-Nov-04 19:09 
GeneralRe: javascriptWindow.Open(...) Pin
Bassam Abdul-Baki22-Nov-04 3:33
professionalBassam Abdul-Baki22-Nov-04 3:33 
GeneralRe: javascriptWindow.Open(...) Pin
rgoyal22-Nov-04 18:07
rgoyal22-Nov-04 18:07 
GeneralRe: javascriptWindow.Open(...) Pin
Bassam Abdul-Baki23-Nov-04 1:36
professionalBassam Abdul-Baki23-Nov-04 1:36 
GeneralRe: javascriptWindow.Open(...) Pin
Steven Campbell23-Nov-04 7:57
Steven Campbell23-Nov-04 7:57 
GeneralRe: javascriptWindow.Open(...) Pin
Bassam Abdul-Baki23-Nov-04 8:25
professionalBassam Abdul-Baki23-Nov-04 8:25 
GeneralRe: javascriptWindow.Open(...) Pin
Anonymous26-Nov-04 18:20
Anonymous26-Nov-04 18:20 
GeneralDrag and Drop Scheduling Interface Pin
skids10118-Nov-04 1:37
skids10118-Nov-04 1:37 
GeneralInserting into Dynamic &lt;Select&gt; Construct Pin
Esther C17-Nov-04 20:02
Esther C17-Nov-04 20:02 
GeneralInserting into Dynamic &lt;Select&gt; Construct Pin
Esther C17-Nov-04 20:02
Esther C17-Nov-04 20:02 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.