![]() |
#2
|
||||
|
||||
![]()
Manual formatting, like that you propose, simply perpetuates the problem. Create (or modify) a paragraph style to provide you with the spacing you want and apply it to the paragraphs.
The following will kill the two birds with one stone, by creating a suitable style in the document (if the name doesn't exist) to apply 36 points of space before each item. Code:
Sub Macro1() Dim oStyle As Style Dim bStyle As Boolean Dim oPara As Paragraph For Each oStyle In ActiveDocument.Styles If oStyle.NameLocal = "Extra Space" Then bStyle = True Exit For End If Next oStyle If Not bStyle Then ActiveDocument.Styles.Add name:="Extra Space", _ Type:=wdStyleTypeParagraph With ActiveDocument.Styles("Extra Space") .AutomaticallyUpdate = False .ParagraphFormat.SpaceBefore = 36 .NoSpaceBetweenParagraphsOfSameStyle = False End With End If For Each oPara In ActiveDocument.Paragraphs If oPara.Range.Text Like "Choice (*" Then oPara.Style = "Extra Space" End If Next oPara lbl_Exit: Exit Sub End Sub
__________________
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 |
Plain Text Content Control - Losing Styling on Carriage Return | kintap | Word | 0 | 07-16-2014 12:43 PM |
![]() |
Alaska1 | Word | 1 | 01-14-2013 08:48 AM |
![]() |
sinbad | Word VBA | 6 | 02-27-2012 03:51 AM |
![]() |
revrossreddick | Word | 2 | 12-28-2011 01:33 PM |
Carriage Return Help | UCHelp | Word | 1 | 04-04-2010 10:11 PM |