![]() |
#1
|
|||
|
|||
![]()
I devised the macro here below to apply Superscript to the last character of a five digit string. It works perfectly, but when I insert the code in a larger macro the last character remains intact. Can someone help? Thanks!
Code:
Dim oRng As Range, iType As Integer For iType = 1 To 2 Set oRng = ActiveDocument.StoryRanges(iType) With oRng.Find .ClearFormatting .Text = "^#^#^#^#^#" While .Execute oRng.Collapse wdCollapseEnd oRng.MoveStart Unit:=wdCharacter, Count:=-1 oRng.Font.Superscript = True Wend End With Next iType |
|
![]() |
||||
Thread | Thread Starter | Forum | Replies | Last Post |
Code to NOT RUN an (autosave) macro within a macro | Kain | Word | 2 | 08-04-2020 06:32 AM |
![]() |
tasneemj | Word | 15 | 02-11-2018 04:12 PM |
![]() |
get4hari | Excel Programming | 8 | 09-26-2015 10:33 PM |
![]() |
rsrasc | Word VBA | 5 | 11-16-2014 05:47 AM |
![]() |
Smallweed | Word VBA | 4 | 01-16-2014 03:15 PM |