tags:

views:

125

answers:

3

I know it's probably something easy but I just couldn't figure it out say I have the following code

string name;

name.LastIndexOf("aaa");

After I type the single quote reshaper will added another for me so I got

name.LastIndexOf("")

After I type aaa I got name.LastIndexOf("aaa|") but now my caret | is sitting inside the double quote...

How do I tell Resharper that I am done so it can add the ; and move to the next line without using the mouse or the direction key?

Perhaps I didn't make myself clear. Using the End key is not much different from the directional key. I was looking for a one step key stroke that will tell Resharper to complete the statement and move to the next block. I think it certain possible since Resharper is so smart. I just couldn't figure it out.

+5  A: 

You can type "), just as you would normally, or press the End key.

Mark Byers
The ") is already there.
firefly
Yep - Resharper uses magic!
Mark Byers
A: 

At that point ReSharper isn't waiting for you to complete a template so you'll need to type [End]; to move to the end of the line and complete the statement.

GraemeF
+4  A: 

You can actually use the Complete Statement feature (which is mapped to Ctrl+Shift+Enter in ReSharper 2.x and IntelliJ IDEA keymap). This will put ';' at the end of the statement and move the caret to the next line

Andrew Serebryansky

related questions