Delete to end-of-file?

A

Anne Troy

I recorded this, Rick:
Selection.EndKey Unit:=wdStory, Extend:=wdExtend
Selection.Delete Unit:=wdCharacter, Count:=1

There's probably a more eloquent way of doing it.
************
Anne Troy
www.OfficeArticles.com
 
T

Tony Jollans

Not, AFAIK, an explicit single command but this should do it:

Selection.EndKey Unit:=wdStory, Extend:=wdExtend
Selection.Delete
 
D

Doug Robbins - Word MVP

Dim myrange as Range
Set myrange=Selection.Range
myrange.End = ActiveDocument.Range.End
myrange.Delete

--
Hope this helps.

Please reply to the newsgroup unless you wish to avail yourself of my
services on a paid consulting basis.

Doug Robbins - Word MVP
 

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