By selecting or clearing check boxes in this tab, you can compile the list of context actions that will be available for C# code. When you highlight the name of a specific context action, you can read its description in the lower part of the tab.
| Name | Description |
|
Add another accessor |
Adds second accessor to an event or property. |
|
Add exception xml comment tag |
Adds exception xml comment tag. |
|
Add explicit name of anonymous property |
Adds explicit name specification to anonymous type property declaration. |
|
Annotate method with 'value can be null' attribute |
Annotates a method with 'value can be null' attribute. The attribute can be configured via
|
|
Annotate method with 'value cannot be null' attribute |
Annotates a method with 'value cannot be null' attribute. The attribute can be configured via
|
|
Apply refactoring |
Applies refactoring. |
|
'catch' to 'catch(Exception)' |
Converts |
|
'catch(Exception)' to 'catch' |
Converts |
|
Change member visibility |
Available on an access modifier keyword and allows changing access rights of a declaration. |
|
Check array index value |
Checks index value for arrays. |
|
Check collection index value |
Checks index value for collections and lists. |
|
Check dictionary key value |
Checks key value for dictionaries. |
|
Check if parameter is null |
Checks function parameter for null. |
|
Check if reference is not null |
Puts the current statement under an |
|
Check if variable is null |
Checks |
|
Check string index value |
Checks index value for strings. |
|
Check StringBuilder index value |
Checks index value for the StringBuilder. |
|
Compute constant value |
Computes value of the current expression and replace it (e.g. 1 + 1 replaced by 2). |
|
Concatenate string |
Converts concatenation of a few strings and other objects to the use of |
|
Convert '==' to 'Equals' |
Converts usage of equality operator ( |
|
Convert anonymous method to lambda |
Converts anonymous method to lambda. |
|
Convert coalescing operator to ternary |
Converts null coalescing operator to ternary conditional operator. |
|
Convert 'Equals' to '==' operator |
Converts a call to the static |
|
Convert explicit to implicit implementation |
Converts explicit implementation of an interface method to implicit implementation. |
|
Convert 'foreach' to 'for' loop |
Works on |
|
Convert 'if' statement to 'switch' statement |
Works on |
|
Convert 'if' statement to ternary expression |
Works on |
|
Convert implicit to explicit interface implementation |
Converts implicit implementation of an interface member to explicit implementation. |
|
Convert instance 'Equals' to static 'Equals' |
Converts a call to instance |
|
Convert lambda body with single return statement to expression |
Converts return statement of lambda body to expression. |
|
Convert lambda expression body to body with single return statement |
Converts expression of lambda body to return statement. |
|
Convert lambda to anonymous delegate |
Converts lambda to anonymous method. |
|
Convert LINQ to methods chain |
Converts LINQ query to extension methods call. |
|
Convert method group to anonymous method |
Converts method group to anonymous method. |
|
Convert method group to lambda |
Converts method group to lambda expression. |
|
Convert 'switch' statement to 'if' statement |
Converts |
|
Convert ternary expression to 'if' statement |
Converts ternary expression whose value is returned or assigned to an |
|
Convert ternary to coalescing operator |
Converts ternary conditional operator comparing value with null to coalescing operator. |
|
Convert to dec |
Converts numeric value from hexadecimal to decimal. |
|
Convert to hex |
Converts numeric value from decimal to hexadecimal. |
|
Convert to regular string |
Converts verbatim string |
|
Convert to verbatim string |
Converts regular string |
|
Copy comments from base |
Copies comments from base to overriding members/types. |
|
Create derived type |
Creates class that implements interface or inherits class. |
|
Create event invocator |
Creates an event invocator. |
|
Create overload without parameter |
Creates overload without given parameter. Calls current method. |
|
Create return from expression statement |
Creates a return statement with value that is taken as an expression statement. |
|
Extract anonymous method to method of the containing type |
Extracts anonymous method as a private method of the containing type. |
|
Flip an invocation expression |
Flips the current invocation expression e.g. |
|
Flip an operator arguments |
Flips left and right arguments for selected operator e.g. |
|
Flip an relational expression |
Flips the current relational expression e.g. |
|
Implement abstract member |
Works on an interface member or an abstract member. Searches for classes where this member needs to be implemented and allows to implement it in one of them. |
|
Implement custom event accessors |
Adds placeholders for custom implementation of |
|
Initialize auto property from constructor parameter |
Optionally creates and initializes an auto property from constructor parameter. |
|
Initialize field from constructor parameter |
Optionally creates and initializes field from a constructor parameter. |
|
Inline as anonymous type action |
Replaces usages of the type in the method with anonymous type usages. |
|
Insert anonymous method signature |
Adds proper signature to parameterless declaration of an anonymous method. |
|
Introduce variable from expression statement |
Introduces a variable from expression statement. |
|
Invert 'if' statement |
Inverts guard condition of an |
|
Invert ternary condition |
Inverts condition and swaps branches of a ternary expression. |
|
Invoke as static method |
Changes invocation syntax from |
|
Iterate via 'foreach' |
Works on an expression of |
|
Join local variable declaration and assignment |
Works on an assignment to a variable that was declared without initializer. Moves the declaration to the current point and merges it with the assignment. |
|
Join string literals |
Concatenates two string literals into one. |
|
Make abstract member virtual |
Makes abstract member virtual. |
|
Make method partial |
Converts private void method to partial method defining declaration. |
|
Match file name with type name |
Renames current file to match the name of the only top-level type declared therein. |
|
Merge nested 'if' statements |
Merges two nested |
|
Merge partial method declarations |
Merges all declarations of a partial method into single declaration. |
|
Merge partial type declarations |
Merges all declarations of a partial type into single declaration. |
|
Move declaration(s) to another type part |
Moves selected declarations range or a single declaration (if invoked without selection on a declaration name) to another type part of a partial type. |
|
Move initialization to constructor(s) |
Works on fields initialized in the declaration. It moves the initialization to constructors. |
|
Move to outer scope |
Moves variable to outer scope. |
|
Move type to another file to match its name |
Moves current type to another file so that its name matches the name of the type. |
|
Negate an relational expression |
Negates the current relational expression e.g. |
|
Override virtual member |
Works on a virtual member. Searches for classes where this member can be overridden and allows to override it in one or all of them. |
|
Put inside 'using' construct |
Converts variable declaration of type that implements the |
|
Remove #region, #endregion directives |
Removes |
|
Remove braces |
Removes unnecessary braces around one or more statements in the code. |
|
Replace ArrayList with List<T> |
Replaces |
|
Replace auto property with backing field |
Replaces auto property with property that utilizes backing field. |
|
Replace backing field with auto property |
Replaces property that utilizes backing field with auto property. |
|
Replace explicit type specification with 'var' |
Replaces explicit type declaration with |
|
Replace 'var' with explicit type declaration |
Replaces |
|
Reverse assignment statement |
Reverses source and destination parts of an assignment statement. |
|
Specify array type explicitly |
Adds explicit type specification to array creation expression. |
|
Split declaration list |
Works on variable declaration statement that declares multiple variables. It splits such statement into multiple statements each declaring a single variable. |
|
Split 'if' with '&&'-condition into nested 'if'-statements |
Works on an |
|
Split 'if' with '||'-condition into assignment to temporary variable and two 'if'-statements |
Works on an |
|
Split local variable declaration and assignment |
Moves variable initializer from declaration statement to separate assignment statement. |
|
Split 'return' with '&&'-condition into guarding 'if' and 'return' |
Works on a |
|
Split 'return' with '||'-condition into assignment to temporary variable, 'if'-statement and 'return' |
Works on a |
|
Split string literal |
Splits string literal into two literals. |
|
Split variable into several ones |
Replaces original variable with several ones declared in inner blocks of the current block. |
|
Surround with "" |
Creates string literal of selection text. |
|
Surround with format |
Surrounds a string with |
|
To assignment statements |
Replaces initializer with a series of assignments. |
|
Use Add() method calls |
Replaces a collection or collection element initializer with a series of |
|
Use 'as' and check for null |
Converts |
|
Use collection initializer |
Replaces a series of |
|
Use object initializer |
Replaces a series of assignments with an object initializer. |
|
Use System.Environment.NewLine |
Replaces literals |
|
Use System.String.Empty |
Replaces |

