Accessing suggested actions in VS2012 using keyboard - visual-studio-2012

When I've added a reference to a class but forgot to add using directive, R# would suggest automatic insertion of it. I'd access that by alt+enter.
Now, I'm on a system without R# and that forces me to use the mouse to unfold that tiny thingy to unfold a suggestion menu. How can I do that from the keyboard? Is it possible at all?

What you're looking for is to expand the Smart Tag menu.
This can be done by pressing the Ctrl + Period (.) shortcut.
You can also use Alt +Shift + F10 shortcut for this.
Edit:
And if by any chance the combo above doesn't work for you, you can re-activate it like this:
1 .
Tools > Customize > Keyboard... (notice the Keyboard... button is at the bottom right of that screen)
2 . Find the View.ShowSmartTag command and set it back to the Ctrl + Period (.) shortcut.

Related

Disable shortcut in Android Studio

I always accidentally do the following keyboard combination SHIFT + ALT + X which will close all of my open files in Android Studio.
UPDATED
My apology, I should have been more clearer asking question. The first thing I did is to google it and I did saw the post in stackoverflow but I can't find SHIFT + ALT + X
See screen shot here:
Go to File -> Settings -> Keymap search for Clear Context and remove or replace the shortcut
Move to File -> Settings -> Keymap and change Keymaps settings to your keymap,for Example : Visual Studio,so that you can use the short cut keys like in Visual Studio.
From here,you can enable or disable any shortcut, you want.
Type in Search, Clear Context.
Then on it Right Click, and you will get your choice.

VS2012 change the Find Dialog (CRL+F) to the old (and working) find dialog

The "new and improved" VS 2012 Find And Replace Dialog, is frustrating me almost every time i have to use it (like every 30 seconds)
Is there way to make the find and replace window in VS 2012 act like it did in VS 2010?
I would like a non-docked, floating, DIALOG -- not the sticky auto-doc thing they have in VS 2012 (2013) now.
It would be nice to have a underlined-letter-hotkeys to navigate the dialog without a mouse, and the window to do not lose focus after search.
The way to make this is to use the FindInFiles dialog.
This can be done by learning to use "Ctl + Shift + F" instead of "Ctl + F" (bad), or simply change the shortcuts to use the old Find-In-Files dialog instead the new "thing" like this:
Tools, Options, Environment, Keyboard
In 'show commands containg:' enter this: FIND
Scroll down to Edit.Find
Remove any existing shortcut (I didn't bother)
Click into 'press shortcut keys' and press CTRL F
Click Assign
Scroll down to Edit.FindinFiles
Remove any existing shortcut (I didn't bother)
Click into 'press shortcut keys' and press CTRL SHIFT F
Click Assign
Hope that this will save you lot of furstration, like it was for me.

ReSharper set GoToNextHightlight to navigate to the errors first

ReSharper manages to find the errors without compiling but they don't seem to have higher priority than other hightlights . When I have a file with a lot of warnings (like unknown css class) I want to ignore, I can't use F12(go to next highlight) shortcut without going through all warnings. Of course I can use the scroll bar to go that error but it would be better to use keyboard shortcut. Any suggestions for this this?
Depending on your keymap:
if using the R# keymap, press ALT + F12
if using the VS keymap, press SHIFT + ALT + PgDn
This will invoke the "Go to next error" command, which ignores warnings, suggestions, etc.

How to remove shortcut command Ctrl+E in Management Studio

I'm really frustrated by this shortcut because I commonly use both Emacs and Management Studio for different projects. However accidentally pressing CTRL + E in MS and expecting cursor to move to the end of the line, which it does in my Emacs configuration, can be really bad in MS if you are programming modifications to a database and, say, are not finished with your WHERE clauses.
I have found no way of redefining CTRL + E to something else, or remove the shortcut entirely. I know I can rightclick the EXECUTE button in the toolbar (no can do in Query menu) and remove the ampersand symbol there but it does not take, CTRL + E still executes my query.
Any help appreciated
For now, there is workaround (map Ctrl + E to some other software):
http://www.sqlservercentral.com/Forums/Topic855640-149-1.aspx
But apparently it cannot be disabled until next version (SQL 2011) :
http://ask.sqlservercentral.com/questions/36303/disable-keyboard-shortcuts
You could install SSMS Tools Pack(it's free). All of its features allow for keyboard shortcut binding, so all you need to do is open the options for one of its features and rebind the shortcut to Ctrl+E. I just tried it now for a coworker who has an identical problem as you. Works great!

Can resharper navigate to a method?

I know how to navigate to a file or a class, but can I navigate to a class's method?
Oh and say I am viewing a different class's file
With respect to my correctly configured keybindings, all of the previous answers seem outdated/invalid to me.
I say:
Hit Alt + \ to list all file members.
Then find your method in the list and navigate to it.
If you use "Resharper 2.x or IntelliJ IDEA" keyboard scheme:
Ctrl + Shift + Alt + N -> navigate to symbol
In Visual Studio Scheme:
Shift + Alt + T
For future reference and other options check https://www.jetbrains.com/resharper/features/navigation_search.html
If you are using Resharper IDEA Scheme, do ctrl + F12 and you can enter a member name, fastest way to navigate to a method, property etc on that file
Ctrl + Click (or Right Click > Go To Declaration). Works on Methods, Fields, Properties, Types, and just about everything else.
With VS2015 and ReSharper 10 press Ctrl + T. This will search for types, symbols and files. It will search through everything in your solution.
Update: works the same in VS2017 and ReSharper 2017.2.
You can also press Ctrl + T followed by / mm to search for just methods.
Another tip for the current file is to use the File Structure window - can also drag and drop members around from the window.
I have used Dpack (f/oss) for years and it can go to methods and/or properties by pressing a shortcut and then start typing. For those who get Resharper's ctrl-T working it is like that one but within the file.
Dpack provides the same functionality for finding files and open files. The former is a better version of Visual Studio 2015's ctrl-;.
(I have done some remapping of keys too but in my experience something (resharper?) overwrites my changes from time to time.)
(Also with VS2015 and R#9.2 I think Dpack does a better job at this.)

Resources