Hi D,
what is D?
like this:
Sub Macro12()
Dim rLprg As Range ' a listparagraph's range
For Each rLprg In ActiveDocument.ListParagraphs
With rLprg.ParagraphFormat
' pseudocode
' .property:=wdconstant or value
End With
Next
End Sub

Signature
Greetings from Bavaria, Germany
Helmut Weber, MVP WordVBA
Win XP, Office 2003
"red.sys" & Chr$(64) & "t-online.de"
DD - 26 Aug 2006 13:50 GMT
Helmut
Are you sure that this will only change the bullets? My report contains
paragraph numbers which I don't need changed.
Also, the macro doesn't work, in debug mode the line...
For Each rLprg In ActiveDocument.ListParagraphs
changes to yellow and I get rLprg = 0
The formatting part is simple enough, I just record what I want it to do,
using a selection. I want to learn how to change a selection macro into a
macro that will select the items for itself. I want to change the macro so
that it goes through the document and changes each bulleted list using the
formatting I have recorded.
This is what I have:
Sub FmtBullets()
Dim rLprg As Range ' a listparagraph's range
For Each rLprg In ActiveDocument.ListParagraphs
With rLprg.ParagraphFormat
.LeftIndent = CentimetersToPoints(2.2)
.RightIndent = CentimetersToPoints(0)
.SpaceBefore = 3
.SpaceBeforeAuto = False
.SpaceAfter = 3
.SpaceAfterAuto = False
.LineSpacingRule = wdLineSpaceSingle
.Alignment = wdAlignParagraphLeft
.WidowControl = True
.KeepWithNext = False
.KeepTogether = False
.PageBreakBefore = False
.NoLineNumber = False
.Hyphenation = True
.FirstLineIndent = CentimetersToPoints(-0.75)
.OutlineLevel = wdOutlineLevelBodyText
.CharacterUnitLeftIndent = 0
.CharacterUnitRightIndent = 0
.CharacterUnitFirstLineIndent = 0
.LineUnitBefore = 0
.LineUnitAfter = 0
End With
Next
End Sub
Regards
Dylan Dawson
Building Surveyor
Glasgow, Scotland
Helmut Weber - 26 Aug 2006 14:04 GMT
Hi Dylan,
programming is very much a process of trial and error,
at least for me.
How about this one:
Sub Macro12A()
Dim rLprg As Paragraph
For Each rLprg In ActiveDocument.ListParagraphs
rLprg.Range.Select ' for testing
'rLprg.Range.ParagraphFormat....
Next
End Sub

Signature
Greetings from Bavaria, Germany
Helmut Weber, MVP WordVBA
Win XP, Office 2003
"red.sys" & Chr$(64) & "t-online.de"
DD - 26 Aug 2006 16:36 GMT
Helmut,
Thanks, I used your advice and your test macro to test the selections.
I also had to dig about a bit further and eventually came up with the
following, which seems to do what I need:
It was actually the ListFormat.ListType property that I was looking for.
Sub FmtBulletList()
Dim rLprg As Paragraph
Dim yPara As Range
For Each rLprg In ActiveDocument.ListParagraphs
If rLprg.Range.ListFormat.ListType = WdListType.wdListBullet Then
Set yPara = rLprg.Range
'rLprg.Range.Select ' for testing
'Clear all tabs and setup new tabs
With rLprg.Range.ParagraphFormat
.TabStops.ClearAll
.TabStops.Add Position:=CentimetersToPoints(11.2 _
), Alignment:=wdAlignTabLeft, Leader:=wdTabLeaderSpaces
.TabStops.Add Position:=CentimetersToPoints(2.2), _
Alignment:=wdAlignTabLeft, Leader:=wdTabLeaderSpaces
End With
'Setup formatting
With rLprg.Range.ParagraphFormat
.LeftIndent = CentimetersToPoints(2.2)
.RightIndent = CentimetersToPoints(0)
.SpaceBefore = 3
' and so on with the formatting
End With
End If
Next
End Sub
Regards
Dylan Dawson