Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 1068349
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 16, 20262026-05-16T20:16:32+00:00 2026-05-16T20:16:32+00:00

The following code opens a link in an existing browser window when browserExe is

  • 0

The following code opens a link in an existing browser window when browserExe is pointing to Firefox, Safari or Chrome. When pointing to IEXPLORE.EXE (IE7) a new windows is opened.

ProcessStartInfo pi = new ProcessStartInfo(browserExe, url);
Process.Start(pi);

This opens a tab in an existing window as intended, when IE is the default browser.

ProcessStartInfo pi = new ProcessStartInfo(url);
Process.Start(pi);

How to i reuse an existing IE windows, when IE is NOT the default browser?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-16T20:16:32+00:00Added an answer on May 16, 2026 at 8:16 pm

    Using shdocvw library (add reference to it, you can find it in windows\system32) you can get the list of instances and call navigate with the newtab parameter:

    ShellWindows iExplorerInstances = new ShellWindows();
    if (iExplorerInstances.Count > 0)
    {
      IEnumerator enumerator = iExplorerInstances.GetEnumerator();
      enumerator.MoveNext();
      InternetExplorer iExplorer = (InternetExplorer)enumerator.Current;
      iExplorer.Navigate(url, 0x800); //0x800 means new tab
    }
    else
    {
      //No iexplore running, use your processinfo method
    }
    

    Edit: in some cases you may have to check if the shellwindow corresponds to a real iexplorer an not to any other windows shell (in w7 all instances are returned, don’t know now for others).

       bool found=false;
       foreach (InternetExplorer iExplorer in iExplorerInstances)
       {
           if (iExplorer.Name == "Windows Internet Explorer")
           {
               iExplorer.Navigate(ur, 0x800);
               found=true;
               break;
           }
       }
       if(!found)
       {
          //run with processinfo
       }
    

    You may also find these additional IE Navigate Flags useful. Full description of the flags are available at http://msdn.microsoft.com/en-us/library/dd565688(v=vs.85).aspx

    enum BrowserNavConstants 
    { 
        navOpenInNewWindow = 0x1, 
        navNoHistory = 0x2, 
        navNoReadFromCache = 0x4, 
        navNoWriteToCache = 0x8, 
        navAllowAutosearch = 0x10, 
        navBrowserBar = 0x20, 
        navHyperlink = 0x40, 
        navEnforceRestricted = 0x80, 
        navNewWindowsManaged = 0x0100, 
        navUntrustedForDownload = 0x0200, 
        navTrustedForActiveX = 0x0400, 
        navOpenInNewTab = 0x0800, 
        navOpenInBackgroundTab = 0x1000, 
        navKeepWordWheelText = 0x2000, 
        navVirtualTab = 0x4000, 
        navBlockRedirectsXDomain = 0x8000, 
        navOpenNewForegroundTab = 0x10000 
    };
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have the following code that opens a new popup window while disabling the
Given the following flow: 1) User clicks on a link, opens a popup window.
I'm using the following code to open the link in a new window, its
I have the following link which opens a jquery modal window: <div id='confirm-dialog'><a href='#'
I have the following code to open a browser in Perl $IE = Win32::OLE->new(InternetExplorer.Application);
In a project i use the following code to open a window: window.open(href, 'mysite'
when clicked from a link on an email, the following code causes a PDF
I have the following code: self.bg_br = mechanize.Browser() self.bg_br.retrieve(self.bg_imageurl, image2.jpg) self.bg_file2 = open(image.jpg, mode=w)
I have a test file that includes the following code. The page opens up
The following code creates a pdf that downloads after you press the link /

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.