Today I was actually wondering why I’ve stuck with it for so many years without actively complaining about it. Doing a “search & replace in all files and folders of a solution” is something I quite regularly need to do, esp. when refactoring tools fail me. Unfortunately, “all folders and files” means “some projects and some other files”. Notably, unconnected files in solution folders, complete web sites and csproj/vbproj/sln files are skipped.
Also, just searching often reveals more hits than replacement replaces (for instance, a csproj is only replaced when its project is unloaded).
Ok, enough complaining: anybody aware of a good plugin or a nice valuable trick that can do a real search and replace through all files and folders of a solution? Something I can rely on?
(edit)
PS: after some more thought: having your system under Subversion or other source control system will make a full search only really valuable when the folder-list could contain a filter of exclusions, i.e., exclude all .svn files and dirs. Unfortunately, as far as I know, that’s not possible with the supplied solution.
While it’s not a plugin for Visual Studio Notepad++‘s find (and replace) in files functionality seems to be solid.
You even get syntax highlighting of your code – though not for aspx files by default. However, this post tells you how to get it working.
UPDATE
You can get a more comprehensive search and replace from within Visual Studio.
Ctrl+Shift+Hto go the the dialog up.Then select the
...button next to the “Look in” drop down to get the “Choose Search Folders” dialog.Pick your folder and then do your search and replace (or just search even).