![]() |
#2
|
||||
|
||||
![]()
Hi angeltread,
Try the following macro: Code:
Sub Capitalize() Application.ScreenUpdating = False Dim oRng As Range, fRng As Range With Selection Set oRng = .Range With .Find .ClearFormatting .MatchWildcards = True .Wrap = wdFindContinue .Forward = True .Text = ": [a-z]" Do While .Execute = True Set fRng = ActiveDocument.Range(Start:=Selection.Start, End:=Selection.End) With fRng .Text = UCase(.Text) .Collapse Direction:=wdCollapseEnd End With Loop End With End With oRng.Select Set fRng = Nothing: Set oRng = Nothing Application.ScreenUpdating = True End Sub
__________________
Cheers, Paul Edstein [Fmr MS MVP - Word] |
|
![]() |
||||
Thread | Thread Starter | Forum | Replies | Last Post |
Wierd symbols inplace of "space", "indentation" etc | aka.bhagvanji | Word | 5 | 02-16-2012 11:50 AM |
"Microsoft Excel Application" missing in the "Component Services" on win08 | sword.fish | Excel | 0 | 02-26-2010 02:09 PM |
How do I change the "and" to "or" with multiple Rules (and Alerts)? | bschimmel | Outlook | 0 | 11-16-2009 05:26 AM |
capitalize first letter of sentences | norco1 | Word | 0 | 06-25-2006 12:37 PM |