returning an xmldocument from a web service

akosz

Newcomer
Joined
Jun 7, 2004
Messages
3
we've got a .net web service and a test app (also written in .net).

the test app passes an XmlDocument byRef to the web service where it is modified. when the web service is done, a return code is sent back.

this worked fine when we passed the xml as a string, but when we changed it to the variable type XmlDocument it blew up on the return. Something about "Invalid Cast".

both the Web Service and the Test App declare the variable as type XmlDocument.

any ideas?

akosz
 
C#:
System.Xml.XmlDocument doc = [/size][size=2][color=#0000ff]new[/color][/size][size=2] System.Xml.XmlDocument();[/size]
[size=2]doc.LoadXml("YourXML here");
Visual Basic:
Dim[size=2] doc as System.Xml.XmlDocument = [/size][size=2][color=#0000ff]new[/color][/size][size=2] System.Xml.XmlDocument()[/size][/size]
[size=2][size=2]doc.LoadXml("YourXML here")
[/size]

Did you try this ?
 
Back
Top