Is there a way to make Visual Studio 2010 auto-completion optional (e.g. keyboard driven) - visual-studio-2010

Visual Studio's auto complete feature is extremely useful but can also be extremely irritating when completing values which are incorrect.
Is there a way to have access to the auto-complete values without having them automatically insert? For example, hitting Ctrl-Space or some other keyboard shortcut when I'm wanting the automatic insertion would be perfect.
I'd also be curious to find out how others deal with this problem.

Tools -> options -> Text Editor -> All Languages (or specific).
Uncheck "Auto list members"

Related

Assigning a shortcut to Visual Assist's quick actions

In plain Visual Studio there is the Alt+Enter shortcut, which brings up a popup with quick fixes and improvement suggestions.
I am using the Visual Assist plugin for c++ development, which lets me right-click on a item and open 'Quick Actions and Refactorings (VA)' menu.
I would like to combine these two options into one: Having the advanced features in the easy accessible Alt+Enter shortcut without reaching to the mouse and right-click. Anyone knows how to assign a custom shortcut to 'Quick Actions and Refactoring'? Or any suggestions how to get rid of the tedious right-click?
Assigning shortcuts always works like this in Visual Studio:
Tools -> Options -> Environment -> Keyboard
Find the right identifier for the desired action, which is
VAssistX.RefactorContextMenu in your case.
Assign the desired shortcut Alt+Enter for the scope Text Editor and there you go.
Note, that this replaces Visual Studio's original Alt+Enter functionality, not blending them together.

Visual Studio code completion like ctrl+k in netbeans?

My question is there code completion for Visual studio like in Netbeans where you cycle the buffer with ctrl+k, when you type something?
There's now a nice extension called Simple Autocomplete which adds one command simpleAutocomplete.next that you can map to a shortcut of your choice.
No, there isn't a similar feature in Visual Studio.
The traditional Visual Studio autocomplete is using intellisense.
When you start typing, intellisense may bring up a drop down with suggestions. In that case you can tab to complete using the current suggestion or use the arrow keys to choose another.
Ctrl-Space (or Alt-Right arrow) will bring up this intellisense menu if it's not up.
I find it does a pretty good job overall.
Some extensions like Resharper or Visual Assist offer their own code completion or other similar features (like Suggestion List for Visual Assist).
I know it's been ages since I asked this question but I found the next best thing to do this. What I would suggest is to use VsVim extension and to use Vim's anyword completion; however, in order for this work, what must be resolved is the keyboard shortcuts that conflict:
Go to "Tools options" in Visual Studio.
Then go to VsVim category(alternatively you can search "VsVim" and
should bring the options) and click keyboard.
As far as I know vim deals with this type of completion with these keys
CTRL+P and CTRL+N so what we do is to let Visual Studio give up
these keybindings and let VsVim deal with it by Selecting from the drop
down of the keys(CTRL+P and CTRL+N) and let it be "Handled by VsVim".
I hope this has helped someone out.

Any light configuration for Resharper 7.1?

I am using Resharper 7.1 only because one function "Clean Code..." with StyleCop settings.
I dont need other things like intellisense or new menus (which actually working extremely slowly).
Is it possible to use some external tool to clean code and disable Resharper in visual studio?
Is it possible to confugure Resharper to disable all his "cool" addons and menus like custom "Rename" and use VisualStudio defaults?
Any other tool that can reformat code with style cop settings without such impact on performance?
You cannot completely turn off all of the ReSharper features, but if you go to ReSharper | Options you can turn off following things:
Environment -> Editor. You can turn off all of the checkboxes. They are responsible for typing assists and can cause typing delays on very slow computers.
Environment -> Intellisense -> General. You can select 'Visual Studio' to turn off advanced intellisense features from ReSharper.
Code Inspection -> Settings. You can turn off 'Enable code analysis'. It is responsible for finding errors in your code and offering quick fixes for them.
Code Editing -> Context Actions and Code Editing -> C# -> Context Actions. You can turn off all of the checkboxes. They are responsible for giving you some of the code editing helpers by Alt-Enter.
Tools -> Unit testing. You can turn off "Enable unit testing" checkbox if you don't use ReSharper unit test runner.
Maybe you should also delete all of the Todo items patterns from Tools -> To-do items.
But the best thing you can do is to ask your boss to buy you a good development workstation with enough memory and SDD - that would be useful even without ReSharper, because your time is many times more expensive. And learn to use advanced ReSharper features. They are really worth it.

How does one set Visual Studio 2010 keyboard shortcuts comfortably, especially when using ReSharper?

In every Visual Studio.NET version you can set keyboard shortcuts using menu Tools -> Options -> Environment -> Keyboard and then find the command you want to assign a shortcut to by entering part of it in "Show commands containing".
For one thing, the listbox is ridiculously short and hard to navigate - is there an alternative?
Then, how do I find out the correct command name for a specific action?
Specifically, I'm using ReSharper 5.1 with Visual Studio 2010 and want to have the Alt + Enter shortcut back (it used to be there in older versions by default) that opens the ReSharper context menu when the cursor is over a curly underline ReSharper uses to highlight errors or warnings.
How do I find out the command name for that (except by an educated guess)?
The way I do this is to perform an action while recording a macro (using Tools / Macro / Record temporary macro).
When I have finished with the action, I look at the source code of the macro and it usually helps to find the correct command.
For example, I have just let R# add some magic through Alt-Enter, and the macro recorder has:
DTE.ExecuteCommand("ReSharper_QuickFix")
You can rebind all of the ReSharper shortcuts by using the ReSharper -> Options -> Visual Studio Integration page. Select a keyboard scheme and hit "Apply Scheme".

Visual Studio: How to make its UI fast, lean and minimal?

Visual Studio can be quite slow to open and work with. The menus and auto-hide windows can get sluggish and commands take a while to start. What are the list of things one can do to make the UI of Visual Studio load faster and operate faster? What settings can one change to make it feel lean and minimal?
PS: I know Visual Studio Express is way leaner and faster. However, I rely on some Visual Studio addons, and addons are not supported in Express.
PS2: I have already closed all unnecessary windows. All diagnostic windows are on auto-hide. And all the tool bars are closed. I work almost completely using keyboard shortcuts.
Here are some tips, actually collected from following blog posts
###VS2008
Improve Visual Studio's Source View Performance
Tips to improve performance of visual studio IDE
Visual Studio 2008 Tweaks
###VS2010
Visual Studio 2010 Performance Part 1: Startup
Visual Studio 2010 Performance Part 2: Text Editor
Visual Studio 2010 Performance Part 3: A Technical Update
###Tips
Turn off background HTML validation.
Go to Tools / Options and select Text
Editor / HTML / Validation in the
tree view on the left side. Uncheck the Show Errors
check box.
Turn off AutoRecover. Go to Tools /
Options and select Environment /
AutoRecover in the tree view.
Uncheck the Save AutoRecover check box.
Close your property grid (View /
Properties Window)
web.config should not have <compilation batch=”false” />
Turn off AutoToolboxPopulate (Tools
-> Options -> Windows Forms Designer set AutoToolboxPopulate False)
Turn off Track Active item (Tools ->
Options -> Projects and Solutions
uncheck Track Active Item in Solution
Explorer)
Disable Navigation Bar(Tools ->
Options -> Text Editor -> C#, uncheck
Navigation bar)
Move file in App_Code into a class
library project
Disable validation Options for HTML
Editing (Tools -> Options ->
Validation -> Clear show error
checkbox)
I know that VS 2008 slowed down from VS 2005. I feel this pain every once in a while when im doing a quick Find or Find-Replace, or Find-In-Solution...etc. The UI sometimes isn't as fast as your hands are (when you're using keyboard shortcuts).
I found that just slowing down sometimes is the way to do it (it sucks, but then again, so does many things about Windows).
If it's load times youre concerned about; disable the startup stuff (from the Options menu). Here you can choose to load a blank screen upon VS load AND not to subscribe to any news feeds. (this helps alot depending on your internet connection).
you can also, via Options, adjust the visual animations that occur, as well as just disabling them altogether.
If there's anything else im missing, which im sure there is, i'd really like to know as well!
One thing that can potentially speed up visual studio is to disable document navigation.
Go to Tools -> Options -> Text Editor -> and uncheck 'Navigation Bar'.
This is definitately an option in 2008, pretty sure its in 2005 too.
Another option to try:
Go to Tools -> Options -> Text Editor and Uncheck 'Track Changes'.
Without knowing the information I posted in the comments I will say the typical stuff. Turn off all addons, if you are using vista or 7 switch to basic vs aero, check all running processes. This is where I would start.

Resources