AspNetAtoms.com daily updates on ASP.NET Tutorials, Articles, Authors and more. Subscribe to our newsletter and receive updates on ASP.NET resources on the Internet.

Categories

Recent Posts

Retrieve data from a web page : Mark Smith

Monday, May 04 2009

An example of how we can make a request to a web page and retrieve the resulting HTML Summary: An example of how we can make a request to a web page and retrieve the resulting HTML There are a few situations where it would be useful to be able to retrieve the HTML from a web page via code. Fortunately, this is made relatively easy by the HttpWebRequest and httpWebResponse classes. Firstly, we need to decide which type of form the web page is using. The two different methods are GET and POST and for this article, I'm going to assume you have a basic understanding of these methods and I'll simply show you an example of how to implement either method rather than go into the differences between them. For both methods we'll need a simple page to actually display the results so let's start by making a page with a TextBox on it....

Read More:
Retrieve data from a web page : Mark Smith
Also See:
Custom Controls And Control Builders : Timothy Khouri
Adding a build banner to ASP.NET Pages : Adam Langley
Include Multiple .Config Files in ASP.NET Web Application : Richard Bean
Generating image thumbnails in ASP.NET : Bertrand Le Roy
Implementing a ICallbackEventHandler in ASP.NET 2.0 : Ashish Sarda

Post your comment

Comment