Searching for Text in Code
To search for specific text in the Code window
1. From the Edit menu, choose Find (Ctrl+F).
2. In the Find What text box, type the text you want to search for. If any text is selected when you choose the command, this text is displayed in the text box. If no text is selected, the word at the current insertion point is displayed.
3. Select a Search option button to specify where to look for the text:
Current Procedure searches in the current procedure only.
Current Module searches in the active module only.
All Modules searches all the code in your project, including all forms.
4. To set limits on the search, select the Match Whole Word Only check box to search only for the complete word by itself, and not as part of another word. Select the Use Pattern Matching check box to search using pattern matching characters .
5. Choose OK.
Visual Basic finds the first occurrence of the text.
6. To find the next or previous occurrence of the text, choose Find Next or Find Previous from the Edit menu.
Ctrl+F Find: display Find dialog box.
F3 Find Next: repeat text search down through your code.
Shift+F3 Find Previous: repeat text search up through your code.
Finding a Procedure
Replacing Text in Code