Re: Macro to delete between lines
From: Dave Lett (dlett_at_NOsmconst.comSPAM.com)
Date: 02/10/05
- Next message: Paul Moloney: "How can I get all docs to display by default as "Final"?"
- Previous message: Carrie Downes: "Re: Find & copy macro--possible?"
- In reply to: Marty: "Macro to delete between lines"
- Messages sorted by: [ date ] [ thread ]
Date: Thu, 10 Feb 2005 11:13:06 -0500
Hi Marty,
The following will delete everything from #111# to #222# including #111# and
#222#
With Selection
.HomeKey Unit:=wdStory
.Find.Execute FindText:="#111#"
.ExtendMode = True
.Find.Execute FindText:="#222#"
.delete
End With
HTH
"Marty" <Marty@discussions.microsoft.com> wrote in message
news:5694BE70-03A1-4A98-8050-C4AEF6BD6712@microsoft.com...
> Hi-
>
> I thank everyone who has been helping me.
>
> Sorry to be a pest, but I have not yet figured out how to do this.
>
> I have a Word97 document with "#111#" and a few pages later, I have
"#222#".
>
> Can a macro be written to delete everything from #111# to #222#?
>
> No matter what I try, I get run-time error 438 "Object doesn't support
this
> opperation or method."
>
> Thanks,
>
> Marty
- Next message: Paul Moloney: "How can I get all docs to display by default as "Final"?"
- Previous message: Carrie Downes: "Re: Find & copy macro--possible?"
- In reply to: Marty: "Macro to delete between lines"
- Messages sorted by: [ date ] [ thread ]
Relevant Pages
|