Find and replace content in a project

Use the Find navigator () to perform search and replace operations across your project.

Find text

  1. Click the search criteria bar, choose Find > Text, and choose a criteria: Containing, Matching, “Starting with”, or “Ending with.”

  2. Enter text into the search field.

  3. Select an option from the case sensitivity pop-up menu: Ignoring Case or Matching Case.

  4. Press Return.

  5. Select a result to show it in the editor area.

Find symbol references

  1. Click the search criteria bar, choose Find > References, and choose a criteria: Containing, Matching, “Starting with”, or “Ending with.”

  2. Enter a symbol name into the search field.

  3. Select an option from the case sensitivity pop-up menu: Ignoring Case or Matching Case.

  4. Press Return.

  5. Select a result to show it in the editor area.

Find symbol definitions

  1. Click the search criteria bar, choose Find > Definitions, and choose a criteria: Containing, Matching, “Starting with”, or “Ending with.”

  2. Enter a symbol name into the search field.

  3. Select an option from the case sensitivity pop-up menu: Ignoring Case or Matching Case.

  4. Press Return.

  5. Select a result to show it in the editor area.

Find the call hierarchy of a method

  1. Click the search criteria bar, choose Find > Call Hierarchy.

  2. Enter a method name into the search field.

  3. Select an option from the case sensitivity pop-up menu: Ignoring Case or Matching Case.

  4. Press Return.

  5. Select a result to show it in the editor area.

Replace instances of found text

  1. Click the search criteria bar, choose Replace > Text, and choose a criteria: Containing, Matching, “Starting with”, or “Ending with.”

  2. Enter text into the search field.

  3. Select an option from the case sensitivity pop-up menu: Ignoring Case or Matching Case.

  4. Enter text into the replacement field.

  5. Press Return.

  6. To replace a single found instance, select the found instance in the results area and click Replace. To replace all instances, click Replace All.

Filter the list of search results

Scope a find or replace operation

  1. When performing a find or replace operation, click the Scope button.

  2. Click a project or group to restrict searching to that project or group, or click New Scope to define a custom scope. A custom scope can restrict searching to files matching a specific location, name, path, extension, type, and source control status.

Find using patterns

Use patterns to refine a search by adding placeholders for white space, URLs, hexadecimal digits and other characters into the search field.

  1. When performing a find or replace operation, click the magnifying glass icon in the search field and choose Insert Pattern from the pop-up menu.

  2. Select a pattern to insert it in the search field.

Find or replace using regular expressions

  1. Click the search criteria bar, choose Find > Regular Expression or Replace > Regular Expression.

  2. Enter a regular expression into the search field or replacement field.

  3. Proceed as you normally would with the find and replace operation.

Note: In General preferences, you can set the amount of detail that appears in the Find navigator. See Manage general environment settings.

See alsoEdit all occurrences of a symbol in your code