Freigeben über


Did you know... How to do a replace all in files? - #081

You could say that all these find tips for the couple of weeks are building up to this tip… how to do a Replace in Files.

Replace In Files window

Just like Ctrl+H does a Quick Replace, Ctrl+Shift+H will bring up the Replace in Files window.  We’ve seen all these options over the past 2 weeks, but there’s just one more now that has become enabled.

Keep modified files open after Replace All

Obviously, if you check this option, all modified files will be opened in the editor.  The significance of this is that you can do an undo, if you change your mind.

If you don’t have this option checked, we’ll prompt you "are you sure you don’t want to do an undo?"

ReplaceAllCaution

After you commit the Replace all with the files opened, if you decide to do an undo, just simply press Ctrl+Z on one of the newly modified / opened files.  You’ll notice that all open files will have the dirty bit * removed, reverting to their previous contents.

Technorati tags: VS2005Tip, VS2008Tip

Comments