ReSharper
 
Get ReSharper
Get your hands on the new features ahead of the release by joining the Early Access Program for ReSharper 2025.1! Learn more

Context actions

Last modified: 25 September 2024

Context actions are code transformations helpers available right in the editor. In contrast to quick-fixes, context actions do not aim to resolve a problem or improve your code, instead, they allow you to quickly introduce minor changes like changing access modifiers, generating code that checks for null, convert 'foreach' to 'for', etc.

ReSharper provides hundreds of context actions in all supported languages. You can find the full list on the Code Editing | Context Actions page of ReSharper options Alt+R, O and in the list of context actions.

This feature is supported in the following languages and technologies:

The instructions and examples given here address the use of the feature in C#. For more information about other languages, refer to corresponding topics in the Languages and frameworks section.