Do you know about Peek Definition Window in #VisualStudio 2013?

Here I continue the series of “What’s new in Microsoft Visual Studio 2013?” and today I will be covering an ultimate tip that a developer working with Visual Studio must know. This will not only help you but will improve your productivity while coding.


In this post, we are going to talk about “Peek Definition Window” that comes with Visual Studio 2013. What does it do? Let’s check out it.


What’s new in Visual Studio 2013?

If you are new to Visual Studio 2013, you may want to check the below posts first:


Peek Definition Window

You must admit that, it is very difficult sometime when you are working on a piece of code and you want to see the implementation of stuffs. In such case, you have to either open that code file in a different window and place it in the second monitor or put it side by side.


To improve the productivity of the developers working with Visual Studio, Microsoft came up with the Peek Definition window by which it will bring the complete definition of the code directly in the part where you are working. Let’s see a demonstration of the same, which will give you more idea about the feature.


Assume, you have this piece of code where you called a static method Demo.Print() from the main method:


Code block


Now you decided to know what has been written inside this method. To do this, you will go to definition by right clicking on the method name or pressing F12 in your keyboard. This actually opens up a document where you will be able to view the entire code. Let us now forget what we can do with earlier versions and see the Peek Definition of that code.


Select the code for which you want to call the Peek Definition Window


To open the peek definition of the selected code, either right click on it and click “Peek Definition” from the context menu or hit the keyboard shortcuts “Alt + F12”.


Click Peek Definition of press Alt   F12


This will open up a small pinned document just below the line where you called Peek Definition window. This will show you the definition of the code, line numbers and/or any other changes. You can notice that, the rest of the lines will shift downwards to place the definition block in that block. Here is a screenshot of the same:


Peek Definition Windows in Visual Studio 2013


In case you decide to open the code block in a document view, click on the small icon placed in between the file name and close icon present at the right corner of the block.


Isn’t it a good feature? Did you like it? Don’t forget to share your feedback about this post. I am available on Twitter, Facebook and Google+, get in touch with me. Stay tuned for more articles in the coming days. Enjoy using Visual Studio 2013 in your day to day coding environment. Cheers.

If you have come this far, it means that you liked what you are reading. Why not reach little more and connect with me directly on Twitter , Facebook , Google+ and LinkedIn . I would love to hear your thoughts and opinions on my articles directly. Also, don't forget to share your views and/or feedback in the comment section below.


  1. great, keep informing us about the product's features

  2. Thanks really its gd to see thanks for information

  3. Great.... Will show the real code flow ...

  4. Great, We will see the real code flow, parameters usage, etc ...


© 2008-2016 - Microsoft Technology Blog for developers and consumers | Designed by Kunal Chowdhury
Back to top