Delete Section breaks from a document

S

Solrac3030

I'm trying to write a macro that would delete all the section breaks in a
document.
 
H

Helmut Weber

Hi Solrac3030,
I'm trying to write a macro that would delete all the section breaks in a
document.

like that:

Sub M2x()
Dim rTmp As Range
Set rTmp = ActiveDocument.Range
With rTmp.Find
.Text = "^b"
.Replacement.Text = ""
.Execute Replace:=wdReplaceAll
End With
End Sub

But I wonder, whether you like the result.

--

Greetings from Bavaria, Germany

Helmut Weber, MVP WordVBA

Vista Small Business, Office XP
 

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