format the XML string

Posted by Itnagaraj under WCF on 7/19/2012 | Points: 10 | Views : 1085 | Status : [Member] | Replies : 2
1. created the WCF Web service and it is working fine. The URL is
http://localhost:1829/Eaxmple_Of_WCFService/Service.svc/getuserlist/a/10

The above service is called in sample.aspx. the code is below

WebRequest request = WebRequest.Create("http://localhost:1829/Eaxmple_Of_WCFService/Service.svc/getuserlist/a/10");
WebResponse ws = request.GetResponse();
//System.Text.Encoding enc = System.Text.Encoding.GetEncoding(1252);
StreamReader responseStream = new StreamReader(ws.GetResponseStream());
string response = responseStream.ReadToEnd();
responseStream.Close();
Response.Write(response);

The "response" string contains following

- <ArrayOfstring xmlns="http://schemas.microsoft.com/2003/10/Serialization/Arrays" xmlns:i="http://www.w3.org/2001/XMLSchema-instance">
<string>amar</string>
<string>*anand</string>
<string>*arun_ar</string>
</ArrayOfstring>

How to format this. Pls any one help me.




Responses

Posted by: Dotnetrajanikanth on: 7/19/2012 [Member] Starter | Points: 25

Up
0
Down
Can you be specific?? Formatting??

____________
www.flickr.com/photos/psdesigner/

Itnagaraj, if this helps please login to Mark As Answer. | Alert Moderator

Posted by: Itnagaraj on: 7/19/2012 [Member] Starter | Points: 25

Up
0
Down
The output like below

amar
*anand
*arun_ar


Itnagaraj, if this helps please login to Mark As Answer. | Alert Moderator

Login to post response