Click here to Skip to main content
Click here to Skip to main content

Run Web Application in Multiple Browsers (Visual Studio)

, 8 Feb 2014 CPOL
Rate this:
Please Sign up or sign in to vote.
Run Web Application in Multiple Browsers (Visual Studio)

Introduction

As a web developer, for performing cross browser testing, we need to run our web site in multiple browsers from Visual Studio. Generally, in a common way, we select a particular browser from the browser selection menu and run the application. However, you can set multiple browsers as your default browser.

Using the Code

When you run the application without debugging (Ctrl+ F5), Visual Studio will run the application in all the browsers, in case of debugging (F5), Visual Studio will prompt you to select a particular browser from the selected default browser list.

In the browser list drop-down, by default, you will be able to see the list of all added browsers, with default browser as checked.

When you select the “Browse With…” option, the following dialog will appear, and you can see the entire list of browsers along with the browser which is marked as “(Default)”.

Now, there can be more than one default browser, and the same has been written in the dialog control as well – “Browsers (Select one or more):”. So, select all the browsers in which you want to run the application together, and click on “Set as Default”. That’s all. Now if you click on “Browse” button in the same dialog control, you will find your web application starts on all the selected browsers at the same time.

If you go back to the Visual Studio main menu, a new option “Multiple Browser” will appear.

Now, if you want to debug the application, and press “F5” or select the multiple browsers options, the following dialog will appear, and you need to select a specific browser from the list of selected browsers.

If you run the application without debugging mode and wanted to run the application to verify the cross browser compatibility, Visual Studio will invoke all the browsers for the same application.

Points of Interest

This feature is really useful for web developers who spend time on cross browser testing! And of course – all the web developers spend time for the same! So, from next time, apply this feature. Wink | ;)

Note: This is not a new feature with Visual Studio 2013, it was available in previous versions as well.

History

  • 8th February, 2014: Initial version

License

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

Share

About the Author

Ahmed Bensaid
Architect Hawaii Consulting
France France

Software architect, web performer and mobile programming explorer ...
Wish to launch his own company in the near future.
 
Personal email : artefakt94[at]gmail.com
Professional email : ahmed.bensaid[at]hawaii-consulting.fr
 
Linkedin | Viadeo
 

Follow on   Twitter   LinkedIn

Comments and Discussions

 
-- There are no messages in this forum --
| Advertise | Privacy | Mobile
Web04 | 2.8.141015.1 | Last Updated 8 Feb 2014
Article Copyright 2014 by Ahmed Bensaid
Everything else Copyright © CodeProject, 1999-2014
Terms of Service
Layout: fixed | fluid