Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. General Programming
  3. C#
  4. using WebBrawser to open a URL from a c# application

using WebBrawser to open a URL from a c# application

Scheduled Pinned Locked Moved C#
csharpperformancetutorialquestion
7 Posts 4 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • S Offline
    S Offline
    shabya
    wrote on last edited by
    #1

    hello, i am using the following code:

    WebBrowser Web = new WebBrowser();
    Web.Navigate("http://...", "_blank");

    . does anyone know if it is memory consuming? and if i dont have internet explorer as a default browser will it work? for example with firefox. tnx , avi

    F A G 3 Replies Last reply
    0
    • S shabya

      hello, i am using the following code:

      WebBrowser Web = new WebBrowser();
      Web.Navigate("http://...", "_blank");

      . does anyone know if it is memory consuming? and if i dont have internet explorer as a default browser will it work? for example with firefox. tnx , avi

      F Offline
      F Offline
      fly904
      wrote on last edited by
      #2

      shabya wrote:

      does anyone know if it is memory consuming?

      Yes, very. It says so in the documentation[^], 'The WebBrowser control is resource-intensive. Be sure to call the Dispose() method when you are finished using the control to ensure that all resources are released in a timely fashion. You must call the Dispose() method on the same thread that attached the events, which should always be the message or user-interface (UI) thread.'

      shabya wrote:

      if i dont have internet explorer as a default browser will it work?

      Yes

      My failometer is detecting vast quantities of FAIL! "Its SQL - hardly programming..." (Caslen)

      1 Reply Last reply
      0
      • S shabya

        hello, i am using the following code:

        WebBrowser Web = new WebBrowser();
        Web.Navigate("http://...", "_blank");

        . does anyone know if it is memory consuming? and if i dont have internet explorer as a default browser will it work? for example with firefox. tnx , avi

        A Offline
        A Offline
        AhsanS
        wrote on last edited by
        #3

        though it is memory consuming but you can use it normal circumstances easily. If you have a very resource hungry application then you should avoid using it. You can use it irrelevant of what your default browser is.

        Ahsan Ullah Senior Software Engineer MCTS 2.0

        1 Reply Last reply
        0
        • S shabya

          hello, i am using the following code:

          WebBrowser Web = new WebBrowser();
          Web.Navigate("http://...", "_blank");

          . does anyone know if it is memory consuming? and if i dont have internet explorer as a default browser will it work? for example with firefox. tnx , avi

          G Offline
          G Offline
          Guffa
          wrote on last edited by
          #4

          shabya wrote:

          and if i dont have internet explorer as a default browser will it work? for example with firefox.

          It still uses Internet Explorer to render the page, regardless of your default browser.

          Despite everything, the person most likely to be fooling you next is yourself.

          S 1 Reply Last reply
          0
          • G Guffa

            shabya wrote:

            and if i dont have internet explorer as a default browser will it work? for example with firefox.

            It still uses Internet Explorer to render the page, regardless of your default browser.

            Despite everything, the person most likely to be fooling you next is yourself.

            S Offline
            S Offline
            shabya
            wrote on last edited by
            #5

            about the browser being opened - what if explorer is removed ? (if it is possible i dont know) i went to the WebBrowser thing because i couldn't open the desired URL in a new window. what happened was it ran over an existing page... the code that i used:

            System.Diagnostics.Process.Start("http://www...");

            . using iexplore /new and stuff doesnt work here tnx

            G 1 Reply Last reply
            0
            • S shabya

              about the browser being opened - what if explorer is removed ? (if it is possible i dont know) i went to the WebBrowser thing because i couldn't open the desired URL in a new window. what happened was it ran over an existing page... the code that i used:

              System.Diagnostics.Process.Start("http://www...");

              . using iexplore /new and stuff doesnt work here tnx

              G Offline
              G Offline
              Guffa
              wrote on last edited by
              #6

              You might be able to remove the Internet Explorer application, but the rendering engine that the control uses is still there. If the browser opens a new window or reuses windows is a choise in the browser settings. In Internet Explorer it's under advanced options and is called "Reuse windows for launching shortcuts".

              Despite everything, the person most likely to be fooling you next is yourself.

              S 1 Reply Last reply
              0
              • G Guffa

                You might be able to remove the Internet Explorer application, but the rendering engine that the control uses is still there. If the browser opens a new window or reuses windows is a choise in the browser settings. In Internet Explorer it's under advanced options and is called "Reuse windows for launching shortcuts".

                Despite everything, the person most likely to be fooling you next is yourself.

                S Offline
                S Offline
                shabya
                wrote on last edited by
                #7

                tnx , but i cant ask my customers to do that , they are usually art and nature like activists...

                1 Reply Last reply
                0
                Reply
                • Reply as topic
                Log in to reply
                • Oldest to Newest
                • Newest to Oldest
                • Most Votes


                • Login

                • Don't have an account? Register

                • Login or register to search.
                • First post
                  Last post
                0
                • Categories
                • Recent
                • Tags
                • Popular
                • World
                • Users
                • Groups