![]() |
|
|
|
#1
|
||||
|
||||
|
Hi Kilosub,
The code's just a series of wildcard Find/replace operations, using a loop (you said you wanted a loop ) to go through a series of them (per the StrFind & StrRep variables) before using two more in linear form for the bolding.The 'save' message is occuring because of how extensive the changes are. You can probably both eliminate the prompt and make the code run faster by adding the lines: Application.ScreenUpdating = False Application.DisplayAlerts = wdAlertsNone immediately after the line: Sub StatementReformatter() and by inserting: Application.ScreenUpdating = True before the line: End Sub As for the spacing, I simply took that from what you'd posted. If you want to reduce the# of empty lines, go to the line: StrRep = "^m^p^p^p^p^p^p\1^p^p ... and decrease the # of '^p' sequences after the '^m'. For example: StrRep = "^m^p^p^p\1^p^p ... will halve the amount of white space. Alternatively (or as well), you could reduce the size of your document's top/bottom margins.
__________________
Cheers, Paul Edstein [Fmr MS MVP - Word] |
|
#2
|
|||
|
|||
|
Hi Macropod,
Lol!! Loop all the way ![]() After adding the code and rerun the same data... it completed approx. 5min. . Awesome...!! Lastly, found "Collection date:" not same row with ""IC/ Passport No:" Thanks and Cheers!! Kilosub |
|
|
|
Similar Threads
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| Looping Question | Steve B | PowerPoint | 0 | 01-19-2011 10:44 AM |
| Looping video | tomasball | PowerPoint | 0 | 10-30-2010 02:38 PM |
| Unbreakable looping | Dixon | Outlook | 0 | 09-23-2009 02:10 PM |
How to Advance from Looping SWF Animation?
|
BSquared18 | PowerPoint | 1 | 07-04-2009 01:56 PM |
| Looping though Custom Properties in VBA | suekay | Misc | 0 | 05-19-2006 06:10 AM |