![]() |
|
#3
|
||||
|
||||
|
I would use a variation on eduzs code and make use of styles which typically have the bold and keep with next settings
Code:
Sub test()
Dim MyPara As Paragraph
For Each MyPara In ActiveDocument.Paragraphs
Select Case Trim(MyPara.Range.Words.First)
Case "Monday", "Tuesday", "Wednesday", "Thursday", "Friday", "Saturday", "Sunday"
MyPara.Style = "Heading 1"
End Select
Next
End Sub
__________________
Andrew Lockton Chrysalis Design, Melbourne Australia |
|
|
Similar Threads
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
Find a sentence that starts with certain words and change the style
|
MAHE | Word VBA | 2 | 02-26-2018 08:40 AM |
| Can I have 2 styles in one paragraph in order to populate a TOC with the first words only? | mlkmnsgrl | Word | 6 | 01-01-2015 10:44 AM |
| Adding All Non-spelling Words in a Paragraph to Dictionary | SQLUSA | Word | 5 | 07-13-2012 04:05 AM |
| reformat file | renato | Word | 1 | 06-13-2012 06:32 AM |
| Huge spaces between words in a justified paragraph! | techdaemon | Word | 2 | 02-22-2010 12:17 AM |