I'm getting quite annoyed with a feature of Resharper that I just cannot find how to disable independently.
With Resharper turned off, whenever I type prop
in VS2015 and press TAB
, I get the following auto-generated code:
public int MyProperty { get; set; }
and I'm then able to switch between int
and MyProperty
repeatedly by pressing TAB
again.
I'm also able to use autocomplete to fill in the variable type as I type.
For example, lets say I wanted to create a property called "test" of type "string", I would do the following:
prop
TAB
to generate the property code templatestri
TAB
to autocomplete the variable type with string
TAB
to move to the variable name placeholdertest
Return
to finishperfect.
However, with Resharper enabled, whilst steps 1,2 and 3 still work, it all goes to pot after that!
If I press TAB to try and autocomplete the variable type, the cursor simply moves over to the variable name, leaving the variable type as stri
.
If I then press TAB
(or even SHIFT+TAB
) again to try and get back to it, it simply finishes the line.
To make things clearer, I've included two gifs demonstrating my problem.
This first one shows what happens with Resharper disabled:
Whilst this one illustrates the frustration I'm currently experiencing with Resharper enabled:
I understand this is an old(er) question and already has an answer; however, I wanted to provide a solution for future SO readers that would allow one to continue using Visual Studio's IntelliSense as opposed to Resharper's.
I had the same issue as the OP (original poster) and found the issue to be caused by a conflict with Resharper's Live Templates. With Resharper enabled, the resolution of prop
after Tab + Tab
, resolves Resharper's prop
Live Template and not Visual Studio's prop
snippet. You might have notice that in OP's 2nd screen cap (the one with Resharper enabled) that the resolution of prop
has a datatype shown as TYPE
instead of int
. This is because Resharper's Live Template has set this parameter name to TYPE
, while Visual Studio's snippet has the same parameter set to int
by default. This is what lead me to look at Resharper's Live Templates for a resolution; lo and behold turning off the prop
Live Template fixes the issue.
Go to Resharper's Template Explorer (Resharper -> Tools -> Templates Explorer
) you will see there is a Live Template named prop
. Simply clear the check box for the prop
Live Template and Visual Studio's prop
snippet resolution, and datatype resolution for that matter, will start working again.
It looks like you have an intellisense setting conflict. Re-Enable Resharper and then change this setting:
Resharper->Options->IntelliSense->General
Change the selection from "Visual Studio" to "Resharper", hit Save and the desired behaviour should be yours.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With