Search Replace inside Word and Excel VBA Code Modules
Posted: Wed Apr 22, 2009 10:02 am
WordPipe and ExcelPipe now support search/replace inside Word and Excel VBA Code Modules.
You need to check the Look In location Code Modules.
You can perform a literal (exact) match using the Search Type Normal search.
Or, you can perform a pattern match using Search Type EasyPattern Wildcards or Perl regexWildcards.
As an example, to replace a subroutine called Sub HelloTest() with a new definition,
Using EasyPattern Wildcards (http://www.datamystic.com/easypatterns_reference.html), set the search text to: and set the replacement text to the new definition (you can paste a multi-line replacement function from the windows clipboard).
Using Perl regexWildcards, , set the search text to: and set the replacement text to the new definition.
You need to check the Look In location Code Modules.
You can perform a literal (exact) match using the Search Type Normal search.
Or, you can perform a pattern match using Search Type EasyPattern Wildcards or Perl regexWildcards.
As an example, to replace a subroutine called Sub HelloTest() with a new definition,
Using EasyPattern Wildcards (http://www.datamystic.com/easypatterns_reference.html), set the search text to:
Code: Select all
Sub HelloTest()[ 1+ chars ]End Sub
Using Perl regexWildcards, , set the search text to:
Code: Select all
Sub HelloTest\(\).*End Sub