In Visual Studio 2010 Solution Explorer tree view, how can I remap the F2 key to Rename the Selected File rather than open Object Browser?
views:
66answers:
2
A:
I don't know about you, but in my copy of VS2010, F2 in the Solution Explorer DOES rename the file. What exactly do you have selected when you hit F2?
djacobson
2010-07-30 21:24:31
The OP likely selected the Visual Basic profile which maps F2 to object browser.
JaredPar
2010-07-30 21:25:58
It opens the Object Browser for me, Visual Studio 2010 Ultimate.
Gordon Bell
2010-07-30 21:26:20
Hmm, then how do I change the profile?
Gordon Bell
2010-07-30 21:27:44
Jared, you're probably right - my keyboard mapping was set to Vis C# 2005 mode. Was just about to edit my answer to provide actual content, but you beat me to it. +1
djacobson
2010-07-30 21:28:33
See Jared's answer to this question, Gordon. :)
djacobson
2010-07-30 21:29:09
+2
A:
Do the following
- Tools -> Options
- Expand Environment and select Keyboard
- Type "File.Rename" into the text box
- Put the Focus on the "Press Shortcut keys" box and hit F2
- Click Assign
JaredPar
2010-07-30 21:25:34