Why doesn't R# replace the variable/prperty/etc with what I selected from Intellisense instead of just pasting?

Answered

If I have a line of code like this:

if (txtThisissometextfields.Text....)

and I want to to replace this field with another one so I put the cursor in front of 'txt' and type txt and get a list of other fields. If I select another option from the list, R# just pastes it in and then I have to edit and remove the extra characters from the previous field. I seem to be doing this quite often. 

It would be nice of R# is smart enough to replace the whole name with the selected one. I don't know if this feature exists and I just have to enable it.

1 comment
Comment actions Permalink

Hello!

 

Thank you for contacting us.

There's option to replace text after the caret whem completing the item, by default it's assigned to Tab key. You can change it to Enter key in ReSharper | Options | Environment | IntelliSense | Completing Characters.

Thank you.

1

Please sign in to leave a comment.