6 New features Shipped With Visual Studio 2013


In this post I'm gonna discuss about 6 new features added to Visual Studio 2013. Keep in mind there are lot more than this list. These are few of them that, everyone might need very frequently. Actually few super cool features...!


  • Peek definition
  • Search facility in option window
  • Quick Launch
  • Enhanced scroll bar
  • Move text with Alt + Arrow
  • 64bit edit & continue

Let's see them one by one.

[1] Peek Definition
In older versions of Visual Studio we are allowed to go to a method declaration by pointing cursor to method and pressing F12 shortcut key or click on go to definition by right clicking. That's fine. But definition window open up as a new separate window.

But in VS 2013 it introduced a new feature called "PEEK DEFINITION" Which opens up the definition window inside the same window. So user no need to swap through various windows & loose the current location.(See figure 1)
short cut: Alt + F12


Fig 1: Peek Definition Window
Inside a peek definition window it is possible to go to a another peek definition window. Then that window change accordingly and it also keep track of recently opened peek definitions.

Another advantage of this option is you can edit inside the peek definition window & save changes right away. Visual Studio keep track of recently opened peek definition windows. We can navigate to them by clicking on little dot in upper right corner of the window. See below image.( See figure 2)

Fig 2: List of peek definition windows


[2] Search facility in option window
This lovely IDE has lots of concerns about users. Comparing to other IDEs available, there are lot of things which can be customized according to preferences of the user. You can change these settings by Selecting

Tools => Options

from top tool bar. There are lot of things. Practically sometimes it is hard to find the place to set those option. Don't worry. With VS 2013 this is just a piece of cake... Did you ever notice the search bar in options window. This newly added feature ease the user with finding whatever the option to change. Just type what you need to find. It will list all settings available, according to your search text.

Fig 3:New Search option in Visual Studio 2013


[3] Quick Launch
Ever had a hard time remembering how to open any window ?? Then this is for you! Just type any thing to find (except content in files). This will show you how to get there.
Fig 4: Quick Launch in VS 2013


[4] Enhanced Scroll Bar
With enhanced scroll bar in VS 2013 you'll get many advantages over a ordinary scroll bar. To enable the feature go to  

Tools => options => Text Editor => All Languages => Scroll Bars 
(See Figure 5)
Fig 5: Enabling Enhanced scroll bar


You can switch between map mode & bar mode. By enabling "preview tooltip mode" you can view some amount of code just by moving the mouse on scroll bar.(See Figure 6)

Fig 6: Preview Tooltip mode


With this new enhanced scrollbar you can easily get an overview of where code changes happens, where find text results are , errors, bookmarks etc...  (can identify according to different colors )
(See Figure 7)

Fig 7: Bar mode color specification


[5] Move text with Alt + Arrow
Cut & paste of any text is just fine. But what if you made a mistake while selecting text or pasting it (Imagine that you cut the code, suddenly one of your peers come and you totally forget to paste the code. Then after some time you come and sit & just save the project :D ) 
With VS 2013 you can move an entire code block using 

Alt + Up/Down arrow keys. 

Select the code block you want & press & hold the Alt key & move the text up or down using arrow keys. That's it. This is a really convenient way to move code here & there.


[6] 64 bit edit & continue
How many of you have experienced the problem that in previous versions of VS didn't allow to edit & continue debugging in 64 bit mode. I'm pretty sure, that most of you have. There are lot of situations that we have to modify the code while debugging. It was not very pleasant to stop the current debugging session, do the modification & debug the code again. With VS 2013 it possible to edit & continue in 64 bit mode also.

That's it for this post. We'll see real soon again.... Until then GOOD BYE....! :) 

Last updated on : 22-March-2015

Find specific text in Database



Hi again...!
In this post I'm going to show you how to find a specific text in  stored procedures, views or table definitions. When database tables, SPs or views increase day by day it is impossible to remember everything in our mind. Few days ago I've come across a situation, where a database table in a production environment getting update incorrectly. I have to find the root cause & after few hours of analyzing we got nothing but a column name, which is updating incorrectly, caused the error.

Then I have to find all the places (all the stored procedures) where that column updating. This is the sql query I've used in that case.

USE Your_DB_Name
GO
SELECT o.name, m.definition, o.type_desc
FROM sys.sql_modules m 
INNER JOIN sys.objects o ON m.object_id = o.object_id
WHERE m.definition LIKE '%employee%'; /*put your search text */

Use a SELECT * and check all the data available for you. Also you can modify this query to find specific text in tables, views, table types etc. Just change the FROM clause (change "sql_modules" into tables, table_types or views)

If you want to find something like "[your_text]" (text with square brackets) use escape character as following

LIKE '%[[your_text]]%' /*wrap text with aextra pair of square brackets*/ 
OR
LIKE '%\[your_text\]%' ESCAPE '\'

Apart from these queries you can use redgate's SQL Search plugin which is freely available good tool.