![]() |
#1
|
|||
|
|||
![]()
I have a script and want to highlight all my lines,
Is there a way to highlight my lines based on a word at the beginning of the line. So for example. Ken: Done the house, top to bottom. Is an example line Hope someone can help Thanks |
#2
|
|||
|
|||
![]()
Hi, I think you'll find this post from a long time ago has the code you may be looking for.
https://www.msofficeforums.com/41614-post5.html Simply substitute "KEN" for "Procedure Step:" |
#3
|
|||
|
|||
![]()
Hi,
Thanks for that, i've tried it and it has highlighted the word but not the line. It'll work for me though, thank you |
#4
|
|||
|
|||
![]()
It worked for me in a mockup. It's possible your script is formatted differently.
Could you post a few pages of it? |
#5
|
||||
|
||||
![]()
'Lines' in Word are a vague concept.
Paul's code highlights from the word to the next paragraph mark, so if the paragraph is more than one displayed 'line' more than one 'line' will be highlighted. If the 'lines' are terminated with a manual line break (Shift+Enter) or copied from this forum you may do better with Code:
.Text = "Ken:[!^13^11]{1,}"
__________________
Graham Mayor - MS MVP (Word) (2002-2019) Visit my web site for more programming tips and ready made processes www.gmayor.com |
![]() |
|
![]() |
||||
Thread | Thread Starter | Forum | Replies | Last Post |
![]() |
abhimanyu | Word VBA | 5 | 03-20-2020 01:33 PM |
How to highlight lines containing specific words | SixStringSW | Word VBA | 4 | 06-03-2018 03:57 PM |
Highlight row based on todays date problem | manxman79 | Excel | 6 | 11-17-2014 09:06 AM |
![]() |
alysolyman | Word VBA | 1 | 03-27-2013 02:46 PM |
![]() |
Learner7 | Excel | 1 | 12-11-2011 02:28 AM |