how to enable visual studio's text editor shift-ctrl-up/down arrow when not working work for BASIC [duplicate] - vb.net

Visual Studio Pro 2019 Version 16.11.1 shift-ctrl-up/down arrow used to jump to LOOP if cursor was at DO, or jump to END IF if was at IF, and vice versa.
But now it does nothing.
How can I fix this?

Make sure you have the option "Highlight related keywords under cursor" enabled in Options.
Tools >> Options >> Text Editor >> Basic >> Advanced >>

Related

How to fix: VB.NET text editor jump from one end of a construct (eg. IF or DO) to the other, no longer works

Visual Studio Pro 2019 Version 16.11.1 shift-ctrl-up/down arrow used to jump to LOOP if cursor was at DO, or jump to END IF if was at IF, and vice versa.
But now it does nothing.
How can I fix this?
Make sure you have the option "Highlight related keywords under cursor" enabled in Options.
Tools >> Options >> Text Editor >> Basic >> Advanced >>

How can I navigate to the next or previous procedure?

In VB6 you can easily go to next procedure by pressing CTRL+Page Down and also previous procedure by pressing CTRL+Page Up.
However I can't find any way to do that using Visual Studio 2010 programming VB.NET; I want to scroll down or up to go to the previous or next procedure using a keyboard shortcut.
Yes, keybindings do exist and you're in luck; the keybindings below relate to Visual Studio 2010's Visual Basic.
It's come to my attention that these default keybindings aren't available in some installations of Visual Studio. If this is the case for you then proceed with the key-binding instructions below this section.
Visual Studio 2005, 2008, 2010
Next Method or Type: CTRL + ↓ or CTRL + PAGE DOWN
Previous Method or Type: CTRL + ↑ or CTRL + PAGE UP
All keybindings for Visual Studio 2010's Visual Basic can be found here, and more keybindings for other programming languages in Visual Studio can be found here
Same keybindings for other versions:
Visual Studio 2012, 2013, and 2015 (and any other version without the default keybindings)
Visual Studio 2012/2013/2015 Does not appear to have any Edit.NextMethod or Edit.PreviousMethod keybindings and the same behaviour can be observed for some installations of other Visual Studio versions, instead you'll have to assign your own:
TOOLS >> OPTIONS >> ENVIRONMENT >> KEYBOARD >> Select Visual Basic 6 from the Apply the following keyboard mapping scheme dropdown:
Find Edit.NextMethod and Edit.PreviousMethod in the Commands box:
Click within the Press Shortcut Keys box and press the shortcut keys you want to assign on the keyboard. In this case, let's copy the shortcut keys from Visual Studio 2010:
Once you've done that, click Assign and then do the same for the other command; the shortcut keys will now work
The Default key-binding is slightly misleading; it only applies if you open a file with Visual Studio that is not supported by the IDE, therefore you should be careful that you do not add a keybinding under this.

Visual Studio 2013 close all Tool Windows

I would be delighted, elated even, if someone could tell me how to close every tool window in Visual Studio 2013 in an automatable fasion. Solution Explorer, Output Window, and Toolbox are all examples of the countless tool windows that can accumulate on my screen. I'm using Autohotkey to try to close them, but it has become impossible to do through blind keyboard shortcuts (AFIK.)
I'm not opposed to a plugin but something with just the keyboard would be ideal.
Thanks so much!
If you want to do it with Autohotkey, take a look at WinClose as MCL suggested. You might also need SetTitleMatchMode.
I'm still using Visual Studio 2010, but with some minor adjustments it should also work in Visual Studio 2012:
SetTitleMatchMode, 2 ;No need to enter the full title
Enter:: ;press enter to close all tool windows
WinClose, Microsoft Visual, Find and Replace
WinClose, Microsoft Visual, Solution Explorer
WinClose, Microsoft Visual, Class View
WinClose, Microsoft Visual, Property Manager
;...
Sleep, 1000
Return
Esc:: ;Use Esc to exit the script
ExitApp
Use "AU3_Spy.exe" form your Autohotkey folder to find the WinTitle(part) and some visible text.
Layouts-O-Rama is my take on the problem. To be found in the vs gallery here:
http://visualstudiogallery.msdn.microsoft.com/35966ad9-430f-4ad7-9186-4394b784e36c
Basically the addin saves tool window layouts. You could simply save a layout with all tool windows closed and assign a hotkey to it. To go even further you could save another layout with all the tool windows you like opened and assign a different hotkey to this.

Attach a keyboard shortcut to 'Collapse All' items in solution explorer with Visual Studio 2012

Like I said in the title of this question, is it possible to attach a keyboard shortcut to collapse all items in the solution explorer with Visual Studio 2012?
In previous version; 2010, I was able to create a macro to enable this feature but in Visual Studio 2012, there is no more support for macros.
I'm able to right click onto item in the solution explorer and choose 'Collapse All' but I prefer to just typed 'Ctrl+Shift+C' to do the same job.
FWIW, this is the best I've been able to come up with so far.
Alternative 1
Press Ctrl+¨ to put focus in the search box above the Solution Explorer.
Press Shift+Tab to move focus to the toolbar.
Use the left arrow to move focus to the left, until you hit the Collapse All button (four times. YMMV).
Alternative 2
Press Ctrl+Alt+l (or whatever your personal shortcut is) to focus the Solution Explorer.
Press Shift+Alt to focus the Solution Explorer toolbar. This puts the focus on the Home button on the toolbar.
Use the right arrow to move focus to the right, until you hit the Collapse All button (three times).
Press Enter.
Alternative 3
Press Ctrl+Alt+l (or whatever your personal shortcut is) to focus the Solution Explorer.
Press and hold the left arrow until you've reached the top node (the Solution node).
Press the up arrow to put focus in the search box above the Solution Explorer.
Press Shift+Tab to move focus to the toolbar.
Use the left arrow to move focus to the left, until you hit the Collapse All button (two times. YMMV).
As you can see in the screenshot below, there is an option called Collapse All and a shortcut key next to it.
Now this shortcut key will not work for you !
Unless ofcourse, you set it up using Tools > Options > Keyboard. The command name is CollapseInSolutionExplorerAction. Search using this command name and assign a shortcut key of your choice.
That's it and you are ready to use your shortcut key !
Source
Visual Studio 2012 / ReSharper 8.0.1:
The command is 'ProjectAndSolutionContextMenus.Project.ReSharper_CollapseInSolutionExplorer'.
I suggest you to try CodeMaid extension for Visual Studio. It provides a command "Collapse All Projects Recursively" that has customizable shortcut (by default, it is Ctrl+M,-). It has some other nice abilities, like switching between .cpp and its .h files, joining lines, etc.
I have searched on the net a way to do this when I have first install VS2012 ..
I have just found the solution, so I share it :)
you can do this by adding your visual studio version to an existing Extension ...
Download the extension for VS 10
Change the extension from vsix to zip
extract it and open the file extension.vsixmanifest
Find this xml section : SupportedProducts
Add this :
<VisualStudio Version="11.0">
<Edition>Ultimate</Edition>
<Edition>Premium</Edition>
<Edition>Pro</Edition>
</VisualStudio>
you can also try version 12 for visual studio 2013 ...
zip it, and change the extension from zip to vsix.
Now you can Install it.
after install it, Goto Tools -> Customise and click on the keyboard button.
Search "CrossProjectMultiProject.CollapseProjects" and assing the shortcut you like.
Have a nice codding.
Please +1 if this help you
ps. sorry for my bad English, im French ;-)

Turn Off Visual Studio/VB.Net Lines around each method

In Visual Studio when working in VB.Net, it automatically creates lines/regions around methods etc.
How can this be turned off somewhere in the options?
If you open Tools ==> Options, and select Text Editor, there is a "Basic" section for Visual Basic. This option is on the "VB Specific" sub-section. Unselect "Show procedure line separators".
Using Visual Studio 2017 and above
For C# and Basic
Open Tools > Options or press Alt + T + O
At the top of the list search for "Show procedure line separators"
select Advanced
In group box Outlining
Uncheck "Show procedure line separators"
This is known as "Outlining Mode" and can be disabled by doing the following
Tools -> Options -> Text Editor
Navigate to the Basic -> VB Specific sub category
Uncheck "Enable outlining mode"
For anyone that comes across this and is using Visual Studio 2012. Those lines are off by default. If you want the lines back then you need to:
Tools -> Options -> Text Editor
Navigate to the Basic -> VB Specific sub category
Uncheck "Enable outlining mode"
Yes, these are the same steps that JaredPar explained to turn the lines off. However, it's completely backwards in 2012 and unchecking this option will bring the lines back.
Way to go Microsoft!
The menu sequence is a bit different for VS2015.
Tools -> Options -> Text Editor -> Basic -> Advanced
Uncheck "Show procedure line separators."