by Rob
24. January 2010 17:13
I've recently been following the Is This Thing On - Visual Studio 2010 tip of the day series. I highly recommend subscribing. The best tip yet was around Reference highlighting. In a nut shell every time you move over a symbol all instances are highlighted. You can see below that all references have been highlighted for MainWindow:

Once the symbols have been highlighted you can move to the next occurrence with Ctrl+Shift+Down Arrow and move to the previous occurrence with Ctrl+Shift+Up Arrow. For ViEmu users it will be unnatural to reach over for the arrow keys, so it's time to remap these using AutoHotkey. The idea is based on this blog post by JP Boodhoo where he maps ReSharper Go to next member to Alt+J and ReSharper Go to Previous Member to Alt+K. So here’s the update you need for your AutoHotkey script:
$^+k:: send, ^+{up}
$^+j:: send, ^+{down}
This will map Ctrl+Shift+J to Ctrl+Shift+Down Arrow and Ctrl+Shift+K to Ctrl+Shift+Up Arrow. Now you can happily move between highlighted references without leaving the home row.
Enjoy