Power of Resharper shortcuts

ReSharper is an intelligent extension for a Visual Studio that supports C#, XAML, XML, ASP.NET and ASP.NET MVC. Using this tool makes code cleaner and more efficient. It’s not cheap but definitely worth it. Below I put some interesting shortcuts to help our daily work.

Search and Navigate:

Ctrl + Shift + G – just Navigate to !
Ctrl + Shift + N – Goto File or Folder
Ctrl + Shift + L – Find symbol
Ctrl + N – File / Symbol / File name (goto stuff)
Alt + F7 – Find result (all usages)
Shift + Alt + F7 – Advanced search of usages, limited amount of results
Ctrl + Shift + F7 – Highlight all occurencies in file
Shift + Alt + L – Locate file in SolutionExplorer
Ctrl + M, Ctrl + L – Toggle collapsing for whole file
Ctrl + M, Ctrl + M – Toggle collapsing for selection
Ctrl + M + G – Move from controller action to specific view
Ctrl + ~ – View Bookmarks window
Ctrl + Shift + [1..9] – Add bookmark
Ctrl + [1..9] – Go to bookmark

Refactor

Ctrl + Shift + R – Refactor this!
Shift + F6 – Rename
Ctrl + R, E – Encapsulate field
Ctrl + F6 – Change method signature
Ctrl + Alt + M – Extract method
Ctrl + Alt + I – Extract interface

Inspect Code Quality

Alt + Enter – Quick fixes and context actions
Ctrl + Space – Symbol Code Completion
Ctrl + Shift + Alt + Up Arrow – Move Code Up
Ctrl + Shift + Alt + Down Arrow – Move Code Down
Ctrl + Q – Quick documentation

Edit Code

Alt + Ins – To generate a member in the current type
Ctrl + D – Duplicate a line or a selected block of code
Ctrl + Alt + Space – When you need an anonymous implementation of a delegate, place the caret where the delegate is expected
Ctrl + Shift + / – Comment a block of code with a block comment
Alt + Ins – To generate a member in the current type

Select

Ctrl + W – extend selection
Ctrl + Shift + W – shrink selection

Other useful tips

Ctrl + F4 – close document tab
Ctro + Alt + T – Unit test explorer window

More tips you can find here.

You may also like...

4 Responses

  1. Przemek says:

    Great post!
    If You want to test Yours knowledge about ReSharper shortcuts this is good site – http://reshortcuts.github.io/

  2. JacekW says:

    Someone can use different R# schema (I’m using Visual Studio) and some shortcuts won’t work 🙂

Leave a Reply

Your email address will not be published. Required fields are marked *