The find-findnext was only a suggestion of something to look into.
Don't know if this is of any use or not.
Here is what I did:
added module2, altered the forms' Search and Extract procedure a little... it's commented.
put a timer in your Find_Whole_Word_CIS1(x) macro.
In it's original state, on my computer, that macro ran in 48 seconds (last input box to first msgbox).
Adding Application.ScreenUpdating=False reduced the time to 9 seconds.
Using .Find and .FindNext (in module2) the time to run was 3 seconds, but the macro is questionable, as the results didn't jive.
The original macro found 2717 records.
60 of those weren't in the results of find/findnext.
I can account for that being 'the' at the beginning of a sentence or first word inside brackets and not having a preceding space.
The find/findnext macro found 3018 records.
361 of these aren't in the original results and I don't know what gives with that.
The attached Comparison workbook contains only the results of the 2 macros, the discrepancies are highlighted.
|