Microsoft has gifted developer community many cool features with the introduction of the Visual Studio 2012. This article speaks about some of the cool features in Visual Studio 2012.
You need to have Visual Studio installed in your computer to check these cool features. If you do not have it installed and if you do not have license for the same you can download the trial version and can test the new version.
Feature 1: Preview Images
We will first discuss the ability to see preview of the image. To do this I have added a JPG file to my existing project as below:
Now place your mouse on the jpg file added in the project and observe. It shows preview of the image.
Pretty cool feature right!!!
Feature 2: View Multiple Solution Explorers (Copy of Solution Explorer in multiple windows)
Will it not be good if we can have two solution explorers where you can select the project from any one of them and drag the explorers anywhere in the screen? It is a fantastic feature provided by Microsoft to the developers.
Let us see how we can view multiple solution explorers. If you observe we already have one solution explorer opened in the Visual Studio and now if you select another one, it will open a copy of the same explorer in another window.
Now right click on the Solution and you will come up with the following options:
You can now expand the one project in one explorer and work on the files.
You can drag the windows anywhere in the Visual Studio editor. This will be helpful when you are working on complex solutions. You can use the features like Scoping and Filtering with the New Solution Explorer feature that we discussed now.
Feature 3: Filters in the Solution Explorer
In the solution Explorer you will find an icon for filtering the files listed in the solution explorer. There are two features available for filtering.
1. Pending Changes Filter
2. Open Files Filter
Before going to test the filter options we need to add our solution to Team Foundation Server so that we can check-in and check-out the files. Pending Changes Filter is used to list only the files that are newly added or modified and are pending for check-in. I have added a JPG file to the project in the solution explorer. So, when I select the option 1 it should show me only the JPG file.
You see that only one project is selected and only the image file is listed.
Open Files Filter is to show only the files opened in the editor and want to get rid of unopened files in the solution explorer.
In my editor I have opened only 3 files and so when I select the second option it should show only the 3 files that were opened.
Now check the files listed in the Solution Explorer:
Now let us see how multiple explorer features helps in regarding to filtering. I have opened a new solution explorer. In the first explorer I have selected Pending Changes Filter and in the second one I have selected the Open Files filter.
Feature 4: Scoping
Let say if you have a solution explorer with multiple projects with many number of files. If you are working on one of the project, you may not like to see all the projects listed out. In that case, the only option available before Visual Studio 2012 is minimize the Projects tree view. But you cannot get rid of them.
Visual Studio 2012 came up with a feature called Scoping. This feature helps you to scope your solution explorer to show only the project that you are working up on.
In my solution explorer I have two projects listed out as below:
Imagine I am working on the project called “AnotherConsole” and so I would like to scope it to this project.
Right click on the project to scope the solution explorer.
Now you see that only one project is listed out in the solution explorer as below:
You can use multiple solution explorers for one window having scoping enabled and other one filtering enabled as below:
If you want to reset the scope option in the solution explorer select “Home” icon on the top.
We will discuss other cool features in the next article. Hope you all have enjoyed this article. Try using these features for your benefit. Happy coding guys!!!!