Deleting Entire Page

G

Guest

Hello,

I'm setting up a template and would like to create a macro to delete an
entire page at once if the user so chooses. The problem is that when I create
the macro to delete line by line and the page is edited, the macro does not
delete the information that was added by the user and the macro gives an
error message.

I'm thinking the only solution to this is to build the macro so that it
highlights the entire page at one time, regardless of what was added or
deleted, and deletes the entire page at once. Is there any command (macro,
keyboard shortcut, etc.) that can delete an entire page in Word at one time?

Thanks for any suggestions,

Dan
 
G

Guest

Hi Anne,

Thanks for the tip, this looks promising. Unfortunately, I'm not very
familiar with Visual Basic. I tried adding "Delete" and "Del" to the code,
but that doesn't seem to be working. Any tips on how to write the code for
delete correctly?

Thanks again,

Dan
 
G

Guest

Hi Anne,

Ignore my last post, I figured it out. Just had to write "Selection.Delete"
and that did the trick. Thanks for the help, this is great.

Dan
 

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