Find Symbol Command

Searches for objects (namespaces, classes, structures, interfaces, types, enums, and so forth) and their members (properties, methods, events, variables, constants, enum items, and so forth) in the current scope.

Edit.FindSymbolsymbolname[/word | /prefix | /substring] [/case | /nocase] [/refs | /norefs]
Edit.QuickFindSymbolsymbolname

Arguments

symbolname
Required. The canonical name of the object or member to find.

Switches

/word or /w
Optional. Searches only for whole words. This switch supersedes /prefix and /substring if they are also specified.
/prefix or /p
Optional. Specifies that the search returns symbols that begin with the string in objectname. This switch supersedes /substring if both are specified.
/substring or /s
Optional. Specifies that the search returns symbols that contain the string objectname.
/case or /c
Optional. Matches occur only if when the uppercase and lowercase characters exactly match those specified in the objectname argument. This switch supersedes /nocase if both are specified.
/nocase or /nc
Optional. Matches occur independent of case.
/refs or /r
Optional. Specifies that referenced components are included in the symbol search. This switch supersedes /norefs if both are specified.
/norefs
Optional. Specifies that referenced components are not included in the symbol search.

Remarks

Switches that are not defined default to the current settings in the Find Symbol dialog box. Executing a command line search does not affect the options specified in the Find Symbol dialog box.

The Edit.QuickFindSymbol command is identical to the Edit.FindSymbol command except that it always uses the options as they are currently set in the Find Symbol Dialog Box without displaying the dialog box.

Example

The first example searches for the substring "cRefs" matching case and including references as if the Find Symbol dialog box had the Match Case and Look In References check boxes selected.

>Edit.FindSymbol cRefs /substring /case

Both of these examples search for "CMyClass" using the options specified in the Find Symbol dialog box.

>Edit.FindSymbol CmyClass
>Edit.QuickFindSymbol CMyClass

See Also

Visual Studio Commands with Arguments | Command Window | Find/Command Box | Viewing and Altering the Browsing Scope | Find symbol Dialog Box | Pre-defined Visual Studio Command Aliases

Show: