Take the 2-minute tour ×
Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

I'm trying to map View.NavigateBackward and View.NavigateBackward like so:

  • View.NavigateBackward = Alt + LeftArrow
  • View.NavigateForward = Alt + RightArrow

Pretty simple to do in Visual Studio with the Keyboard Options dialog. OK so I've assigned the shortcuts and the NavigateBackward one is working. But NavigateForward, which used to be assigned to Edit.CompleteWord, is staying with its old assignment. I've checked that Edit.CompleteWord is assigned to 'Ctrl+K, W' but the Alt+RightArrow is still behaving as complete word. Is there something special about the arrow keys that I can't assign them?

I want to do this so the mouse buttons behave the same in VS 2010 and my web browser. Works fine for the back button, but the forward button won't re-assign properly. Suggestions?

share|improve this question
add comment

2 Answers 2

Classic "figured it out 30 seconds after I posted": you have to remove the Edit.CompleteWord keyboard assignments in all editors -- even though Alt + Right Arrow was assigned in Global as View.NavigateForward. Apparently Global doesn't override all editors like it should.

share|improve this answer
    
Thanks, I was searching for that for the exact same reason. –  blez Jun 12 '13 at 13:41
add comment

To expand on jcollum's answer...

Apparently, assigning at the global level does not mean "take effect globally". It appears instead it is a "fallback" when there is no more-specific assignment for the current editor type or window.

So, if you're not getting the global key assignment to behave, in this case Alt+Right Arrow, go to Tools-Options, Environment, Keyboard.

Click in the "Press shortcut keys" field, and press the Alt+Right Arrow combination.

Then click the "Shortcut current used by" drop down, and you'll see the offending command that is taking precedence, like "Edit.CompleteWord (Alt+Right Arrow (Workflow Designer))"

Keyboard screen1

Next, type the offending command into the "Show commands containing" field. i.e. type Edit.CompleteWord. Now click the "Shortcuts for selected command" drop down. Select the one that is overriding Alt+Right Arrow, then click Remove.

keyboard screen2

Now, your global assigned shortcut will be used (assuming there aren't other shortcuts taking precedence).

share|improve this answer
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.