Results 1 to 3 of 3

Thread: Internet Interaction Advice

  1. #1

    Thread Starter
    Lively Member
    Join Date
    May 2008
    Posts
    113

    Internet Interaction Advice

    Hi,
    I need some advice from experienced .net programmers.
    I have written a few little applications that interact with the internet, I have been mainly using the webbrowser control for this, however I keep coming across posts on various forums that claim that it is far better to use httpwebrequest class when dealing with the internet.

    Is this true and if yes, why?

    Thanks

  2. #2
    Super Moderator jmcilhinney's Avatar
    Join Date
    May 2005
    Location
    Sydney, Australia
    Posts
    111,221

    Re: Internet Interaction Advice

    The WebBrowser is a control. The point of a control is to interact with the user, i.e. display data and receive input. If you're not specifically interacting with the user then a control is generally not the best choice. There's a considerable overhead associated with the UI and that's wasted if you aren't I'ing with the U. Generally speaking, if you want to perform web-based tasks in code then the WebClient class should be your first choice, mainly because it's simple, and then you should look at a WebRequest if you need greater control than the WebClient offers.
    Why is my data not saved to my database? | MSDN Data Walkthroughs
    VBForums Database Development FAQ
    My CodeBank Submissions: VB | C#
    My Blog: Data Among Multiple Forms (3 parts)
    Beginner Tutorials: VB | C# | SQL

  3. #3

    Thread Starter
    Lively Member
    Join Date
    May 2008
    Posts
    113

    Re: Internet Interaction Advice

    Thanks jmcilhinney,
    Looks like I have hot some reading to do.....

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width