![]() |
|
#1
|
|||
|
|||
![]() Because of the problem mentioned by Guessed, I've now uploaded a new test.docx as an attachment -- If there is a better way, please let me know. |
#2
|
|||
|
|||
![]()
Thank you, macropod, for your code. I tried it on the test.docx I provided and it seems to work for the first line.
But then it seems to get stuck in this loop when it hits a particular wdColorAutomatic Code:
Do While .End < Rng.End - 1 If .Characters.Last.Next.Font.Shading.BackgroundPatternColor = _ .Characters.First.Font.Shading.BackgroundPatternColor Then .End = .End + 1 Else Select Case .Font.Shading.BackgroundPatternColor Case wdColorAutomatic Case wdColorWhite: .Collapse wdCollapseEnd Case Else ... End Select |
#3
|
||||
|
||||
![]()
The code works fine for me with your test document.
__________________
Cheers, Paul Edstein [Fmr MS MVP - Word] |
#4
|
|||
|
|||
![]()
macropod: The code works fine for me with your test document.
I just tried it again and it works fine for the first 4 highlights (in the first line) but then it get's stuck and never finds the highlight info for the turquoise " uif 5ifbwfot boe u" Do you get info for that one? |
![]() |
|
![]() |
||||
Thread | Thread Starter | Forum | Replies | Last Post |
![]() |
ajanson | Word | 3 | 08-15-2016 04:49 PM |
![]() |
DougsGraphics | Word VBA | 2 | 06-24-2015 07:31 AM |
![]() |
tluken | Word | 1 | 08-23-2012 10:20 AM |
![]() |
WilltheGrill09 | Word | 1 | 03-27-2012 02:44 AM |
![]() |
b0x4it | Word | 4 | 05-18-2011 07:54 PM |