Prev Next

Search in Files

File Text Searches are provided by the Find in Files window and from within the Code Editors, to search files for data names and structures. These files can be external code files, code files that you have already opened in Enterprise Architect, internal model scripts or the Help subsystem.

The 'File Search' tab maintains a history of the file paths you have explored, helping you to quickly return to frequently-used folders in your file system. You can similarly select a previously-used search string, if you need to repeat a search several times. When you are searching code files, you can also confine the search to files of specific types, by selecting the file extensions, and to include just the selected folder or all of its subfolders as well. Another useful facility is being able to select to show the results of the search as either a list of every instance of the string, or a list of files containing the string with the instances grouped under the file in which they are found.

For all searches, you can qualify the search to be case-sensitive and/or to match the search string to complete words.

Access

Ribbon

Start >  Explore > Search > Files

Context Menu

Right-click on selected text | Search for <selected text> | Search in Files

Keyboard Shortcuts

F12, Ctrl+Shift+Alt+F

Search Toolbar

You can use the toolbar options in the Find in Files window to control the search operation. The state of each button persists over time to always reflect your previous search criteria.

Options

Option

Action

See also

The 'Search Path' field. Specify the folder to search, or the type of search.

You can type the folder path to search directly into the text box, or click on the drop-down arrow and select 'Browse for folder' to search using the 'Browse for Folder' dialog.

Any paths you enter are automatically saved in the drop-down list, up to a maximum of ten; paths added after that overwrite the oldest path in the list. You can select one of these saved paths if you prefer.

Apart from 'Browse for folder', there are three other fixed options in the drop-down list:

  • 'Search in scripts', which searches the local and user-defined scripts in the 'Scripts' tab of the Scripting window
  • 'Search in open files', which confines the search to the files that you have open in Enterprise Architect
  • 'Search in local help', which searches the local Help files that have been installed from the Sparx Systems web site; the results list the Help topics containing the search term, and the line number and line in which the text occurs

These options disable the 'Search File Types' list box.

The 'Search Text' field. Type the text string to search for.

Any text you type in is automatically saved in the drop-down list, up to a maximum of ten strings; text added after that overwrites the oldest text string in the list. You can click on the drop-down arrow and select one of these saved text strings, if you prefer.

The 'Search File Types' field. Click on the drop-down arrow and select the file types (file extensions) to search.

Click on this icon to begin the search.

During the course of the search all other buttons in the toolbar are disabled. You can cancel the search at any time by clicking on the Search button again.

If you switch any of these toggle buttons, you must run the search again to change the output.

Click on this icon to toggle the case sensitivity of the search. The tool-tip message identifies the current setting.

Click on this icon to toggle between searching for any match and searching for only those matches that form an entire word. The tool-tip message identifies the current setting.

Click on this icon to toggle between limiting the search to a single path and including all subfolders under that path. The tool-tip message identifies the current setting.

Click on this icon to select the presentation format of the search results; you have two options:

  • List View  - (as shown) each result line consists of the file path and line number, followed by the line text; multiple lines from one file are listed as separate entries
  • Tree View - () each result line consists of the file path that matches the search criteria, and the number of lines matching the search text within that file; you can expand the entry to show the line number and text of each line

Click on this icon to add a new search tab. You can create up to four new search tabs. Searches can also run concurrently.

Click on this icon to clear the results.

If necessary, click on this icon to remove all the entries in the Search Path, Search Text and Search File Types drop-down lists.

Click on this icon to display this Help topic.

Learn more