Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Dataset or XML
Message
From
10/10/2003 20:29:03
 
 
To
10/10/2003 20:15:49
General information
Forum:
ASP.NET
Category:
Other
Title:
Miscellaneous
Thread ID:
00837727
Message ID:
00837731
Views:
32
Yeah, you could return a DataSet, but then if there will *ever* be a need for the WebService to consumed by other than a .NET client, then you're stuck. We return XML from all our WebServices. It's easy to put this into a DataSet without much trouble at all.
public void ImportXML(DataSet Data, string XML)
{
  StringReader sr = new StringReader(XML);
  Data.ReadXML(sr, XmlReadMode.InferSchema);
  Data.AcceptChanges();
}
~~Bonnie

>My Web Service always returns data in XML string. From the client side, this requires the client to manipulate that XML string in order to get the data in the way it is desired. From VFP, this can be accomplished by using XMLTOCURSOR(). But, outside of that environment, the client would have to DOM into the XML string and get the piece of data that is required for the display or any other kind of needs.
>
>Knowing that the Web Service is done in .NET and that the client who would access some specific methods would also be .NET, would that be the best way to simply return a DataSet?
>
>I would like some feedback on both approaches in regards to the pros and cons.
Bonnie Berent DeWitt
NET/C# MVP since 2003

http://geek-goddess-bonnie.blogspot.com
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform