ReSharper 8.0 Web Help

To view the drop-down list of available context actions and apply one of them
  1. Click a line in the source code to see whether any context actions are available for the code that it contains:
    • There are available context actions if one of the following icons is displayed to the left of the code line: Coding_Assistance__Context_Actions__icon_editing Coding_Assistance__Context_Actions__icon_refactor Coding_Assistance__Context_Actions__icon_navigate
    • There may or may not be available context actions if one of the quick-fix icons is displayed to the left of the code line: yellowBulb redBulb
  2. If one of these icons displays, press Alt+Enter to display a drop-down list and see which context actions are available, if any:
    Coding_Assistance__Context_Actions__drop-down_list
  3. Select the desired action from the drop-down list, and press Enter.

In some cases, a context action deploys a template where you should choose values for a set of template parameters. For example, here's what happens when you apply the Iterate collection via 'foreach' context action:

Coding_Assistance__Context_Actions__foreach_01

After creating the foreach statement, ReSharper puts focus on the type of collection items to help you make sure that it's specified correctly. You can modify the type name by typing directly in the blue box:

Coding_Assistance__Context_Actions__foreach_02

After that, press Tab to switch focus to the next template parameter, which contains the collection index. Type a custom name right over the default one if required:

Coding_Assistance__Context_Actions__foreach_03

Press Tab once again to put the caret into the statement body:

Coding_Assistance__Context_Actions__foreach_04