To inline a method
  1. Position the caret at a method declaration or method call to inline, or select a method declaration in File Structure:
    Inline Method refactoring
    Image 1:
  2. Choose ReSharper | Refactor | Inline, or press Ctrl+Alt+N. The Inline Method dialog box will display:
    Inline Method refactoring
    Image 2:
  3. Specify refactoring options:
    • Inline all usages: if selected, inlines all usages of a method. If deselected, inlines only the method call that you positioned the caret at in the text editor. Becomes inactive in selected mode if the refactoring is executed upon a method declaration.
    • Remove inlined method declaration: if selected, removes the original method; otherwise, leaves it as is, without any usages.
  4. Click Next. If no conflicts are found, the refactoring will be successfully completed:
    Inline Method refactoring
    Image 3:
  ReSharper will display a warning if you attempt to inline a method that has no usages, such as a Main() method.