Insert Bullet

R

Richard

Hi

I am trying to insert a bulleted point with this:

With wrdCell.Range
.AutoFormat
.Text = "Text First Line"
.InsertParagraphAfter
.Collapse (wdCollapseEnd)
.End = .End - 1
.ListFormat.ApplyBulletDefault
.Words(1).Font.Name = "Arial"
.Words(1).Font.Size = 10
.Words(1).Font.Italic = False
.InsertAfter "Text second line"
End With

The result is:

Text First Line
- Text second line
-

with and extra bullet. How do I code it to remove the second bullet or
please edit my code.

Many thanks in advance.
Richard
 
R

Russ

Selection.Range.ListFormat.ApplyBulletDefault
Toggles bullets on and of for the selected paragraph(s), depending on
current status.
So you might try fiddling with:
Selection.Collapse(wdCollapseEnd)
Selection.Range.ListFormat.ApplyBulletDefault

But I don't see where the second paragraph mark for the second bullet was
entered?
 
R

Richard

Thanks Russ for your comment.

Doesn't work. I am over my head to where the other bullet is coming from.

Richard
 
R

Richard

I checked and the problem lies with the underlying record. It was copied and
pasted over so there was a line / row after the text resulting in the
additional bullet.

Thanks anyway
Richard
 
R

Russ

Richard,
Glad you found the answer.
By the way, I wasn't clear in my previous post about what to fiddle with. I
didn't mean to fiddle with your original lines of

Selection.Collapse(wdCollapseEnd)
Selection.Range.ListFormat.ApplyBulletDefault

But I meant to try to use those same two lines later to try to turn off the
bulleting before that last paragraph mark. For cleanup purposes after
turning off the bulleting, you may have wanted to add code to also delete
that extra paragraph mark at the end.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top