Click here to Skip to main content
15,867,568 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
Hi everyone.

I have to receive a Xml-Sheet from a webserver and I don't know how to do this.
The request should be a https call - which is generated in my program. When I open this url with the browser, I get a Xml-Sheet back.
Now I want to receive this xml-Sheet with my program and i want to read it.
Can you help me ?
(I prefere to do it in vb.net but c# would be also possible..)

Thanks!
Z
Posted
Comments
Estys 23-Jan-11 4:55am    
I removed your "Answer" and added it as comment to the answerer. Giving answers to yourself will not get noticed by the intended person but adding comments will.

1 solution

Use HttpWebRequest, and you'll get a web page back. At that point, you can parse the html/xml. There are several CodeProject articles that discuss how to do these things. I've written a couple, as have others:

CodeProject Article Scraping[^]

CodeProject Article Scraper, Revisited[^]

CP Vanity[^]
 
Share this answer
 
Comments
Sergey Alexandrovich Kryukov 18-Jan-11 11:35am    
Nice examples (a 5).
Estys 23-Jan-11 4:46am    
From The.Z :

Thanks for your help!

But it still doesn't work...^^
Do you know prowl? It is a online-service where you can send Push-Alerts to your Iphone.
They offer a .net dll but I don't know how to handle this class.
So i have decided to write my own code (and I don't want to add another dll to my project..).

Now I am able to "contact" these prowl-server with my message and api-key with the HttpWebRequest, but I can't read the xml.

The url contains all important parameters. When I launche this code, the Prowl-Server sends me the push alert. But i want to receive the xml because my programm don't know that the request was sucessfull.

Dim myHttpWebRequest As System.Net.HttpWebRequest = System.Net.WebRequest.Create(url)
Dim result As IAsyncResult = myHttpWebRequest.BeginGetResponse(Nothing, Nothing)
Regards,
The.Z

Removed Answer

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900