Results 1 to 2 of 2
2010-12-27, 12:01 #1
- Join Date
- Jan 2010
- Montevideo,Montevideo, Uruguay
- Thanked 0 Times in 0 Posts
I have more than 1000 MS Office documents (mostly .doc, .docx, .xls and .xlsx) in a file server shared folder.
I need to do a general search and replace of a specific character string into all of them. More precisely, I need to find all documents containing the string "ISO 9001:2000" and replace ir with "ISO 9001:2008".
Is there a way to do it in batch mode, without having to open one by one with Word or Excel?
2010-12-27, 13:47 #2
- Join Date
- Feb 2001
- Silicon Valley, USA
- Thanked 93 Times in 89 Posts
The documents need to be opened, edited, and saved, but in many cases this could be automated.
The first step would be to build a macro (VBA procedure) that reliably makes the change you want to make. Since you plan to save over the originals, you might want to test on several documents.
The second step is to borrow some code to loop through a set of folders and subfolders identifying documents to open, edit, and save. There have been many examples of that on the Word board over the years, but I'm sure you can search for them as readily as I can.
I'm not sure about Excel.
You might need to adjust your settings if you have Office 2007 prompt you to convert the format or warn you about lost formatting. Otherwise, your procedure may require spending a lot of time dismissing dialogs.