ProblemYou want to find the files or folders that match certain criteria. SolutionUsing a graphical user interface
Using a command-line interfaceThe where.exe utility searches the files in your path that match a pattern. This command finds all files that begin with net and have a .exe extension: > where net*.exe You can also use where to find files in a specific folder or tree of folders. This command finds all .vbs scripts whose names contain the letters foo: > where /r c:\scripts *foo*.vbs Windows comes with two other tools you can use to search for files that contain a certain string: find.exe and findstr.exe. The latter is more robust. If you only need to find the files in the current directory that contain the letters log, you can use this command: > findstr log * This next command performs a case-insensitive search (/i) for all nonbinary files (/p) on the d: drive (/s) that contain the text "confidential" (/c): > findstr /s /p /i /c:"confidential" d:\* findstr includes some regular expression support. For a list of all the features, look at the command help information (findstr /?). Using downloadable softwareWith the introduction of Google Desktop search (http://desktop.google.com) in 2004, providing robust search capability for local files became a hot topic. Before long, both Yahoo (http://desktop.yahoo.com) and Microsoft (http://beta.toolbar.msn.com) released similar tools. All are free and provide roughly the same features. Take a look at each tool's web site for more information about the types of files that are indexed and can be searched. If you want to search for strings within binary files, take a look at the Sysinternals strings.exe command. The following command displays any text strings contained in binary files within the Program Files directory: > strings -s "c:\program files" See AlsoMS KB 185476, "HOWTO: Search Directories to Find or List Files," and "Inside Secrets of MSN Desktop Search" at http://www.windowsdevcenter.com/pub/a/windows/2004/12/21/msd_desktop_search.html |