Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Visual Studio Alt and Arrow Up/Down is not working

Alt+ and Alt+ is not working in Visual Studio. Some people don't use it, but for those who do it's annoying when it's not there.

I expect the shortcuts to move the selected lines up/down.

like image 807
Gutek Avatar asked Sep 07 '17 10:09

Gutek


People also ask

Why does Ctrl Alt Arrow not work?

You can change your screen orientation in the Display settings if you want to rotate your screen but Ctrl+Alt+Arrow keys is not working. To do so, kindly follow these steps: Right-click on your desktop and select Display settings. Select your preferred screen orientation under the Orientation tab.

How do I enable Keyboard Shortcuts in Visual Studio?

On the menu bar, choose Tools > Options. Expand Environment, and then choose Keyboard. Optional: Filter the list of commands by entering all or part of the name of the command, without spaces, in the Show commands containing box. In the list, choose the command to which you want to assign a keyboard shortcut.

How do I reset key bindings in Visual Studio?

Click File > Preferences > Keyboard Shortcuts. There is a triple-dot (...) at the top-right hand corner. Click on that and select "Show User Keybindings" Delete your listed keybindings.

How do I move a selection line in Visual Studio?

If you go to Edit -> Advanced -> Move Selected Lines Up / Down you can see if the shortcut is there or not. If I go to Tools -> Options... -> Environment -> Keyboard -> Edit. MoveSelectedLinesUp / Edit.


1 Answers

Go to Tools\Options... in the menu, then Environment\Keyboard in the tree view and search for

  • Edit.MoveSelectedLinesDown, and
  • Edit.MoveSelectedLinesUp

Add global shortcuts for them: Alt+Down Arrow and Alt+Up Arrow respectively.

Screenshot from Visual Studio 2019

like image 128
Gutek Avatar answered Oct 06 '22 01:10

Gutek