Reply
 
Thread Tools Display Modes
  #1   Report Post  
Posted to microsoft.public.word.docmanagement
MarkN MarkN is offline
external usenet poster
 
Posts: 18
Default Copy everything except headers and footers

Hello,

Is there a way to copy a large, multi-sectioned document without copying the
headers and footers?
--
Thanks,
MarkN
  #2   Report Post  
Posted to microsoft.public.word.docmanagement
Cindy M. Cindy M. is offline
external usenet poster
 
Posts: 2,416
Default Copy everything except headers and footers

Hi Mark,

Is there a way to copy a large, multi-sectioned document without copying the
headers and footers?

Not in one step, no. The header/footer information (along with margin settings,
number of columns) is stored "in" the section break. So you'd have to copy each
section without the section break.

Cindy Meister
INTER-Solutions, Switzerland
http://homepage.swissonline.ch/cindymeister (last update Jun 17 2005)
http://www.word.mvps.org

This reply is posted in the Newsgroup; please post any follow question or reply
in the newsgroup and not by e-mail :-)

  #3   Report Post  
Posted to microsoft.public.word.docmanagement
MarkN MarkN is offline
external usenet poster
 
Posts: 18
Default Copy everything except headers and footers

Thanks for your prompt response. Is there a VBA solution for this, or I was
thinking about a macro to delete the headers and footers before copying the
document. So I would run the header removing macro in the source document,
copy and paste into the destination document and then close the source
document without saving it.

My plan seems pretty inefficient though. Do you have any better suggestions
for a coded solution.
--
Thanks in advance,
MarkN


"Cindy M." wrote:

Hi Mark,

Is there a way to copy a large, multi-sectioned document without copying the
headers and footers?

Not in one step, no. The header/footer information (along with margin settings,
number of columns) is stored "in" the section break. So you'd have to copy each
section without the section break.

Cindy Meister
INTER-Solutions, Switzerland
http://homepage.swissonline.ch/cindymeister (last update Jun 17 2005)
http://www.word.mvps.org

This reply is posted in the Newsgroup; please post any follow question or reply
in the newsgroup and not by e-mail :-)


  #4   Report Post  
Posted to microsoft.public.word.docmanagement
Jezebel Jezebel is offline
external usenet poster
 
Posts: 1,384
Default Copy everything except headers and footers

If you're going to use VBA, rather than removing the headers and footers, it
would be easier just to copy the content of the document body section by
section, and paste that into the new document.





"MarkN" wrote in message
...
Thanks for your prompt response. Is there a VBA solution for this, or I
was
thinking about a macro to delete the headers and footers before copying
the
document. So I would run the header removing macro in the source document,
copy and paste into the destination document and then close the source
document without saving it.

My plan seems pretty inefficient though. Do you have any better
suggestions
for a coded solution.
--
Thanks in advance,
MarkN


"Cindy M." wrote:

Hi Mark,

Is there a way to copy a large, multi-sectioned document without
copying the
headers and footers?

Not in one step, no. The header/footer information (along with margin
settings,
number of columns) is stored "in" the section break. So you'd have to
copy each
section without the section break.

Cindy Meister
INTER-Solutions, Switzerland
http://homepage.swissonline.ch/cindymeister (last update Jun 17 2005)
http://www.word.mvps.org

This reply is posted in the Newsgroup; please post any follow question or
reply
in the newsgroup and not by e-mail :-)




  #5   Report Post  
Posted to microsoft.public.word.docmanagement
MarkN MarkN is offline
external usenet poster
 
Posts: 18
Default Copy everything except headers and footers

Good idea, I'm off to borrow some code...
--
Thanks,
MarkN


"Jezebel" wrote:

If you're going to use VBA, rather than removing the headers and footers, it
would be easier just to copy the content of the document body section by
section, and paste that into the new document.





"MarkN" wrote in message
...
Thanks for your prompt response. Is there a VBA solution for this, or I
was
thinking about a macro to delete the headers and footers before copying
the
document. So I would run the header removing macro in the source document,
copy and paste into the destination document and then close the source
document without saving it.

My plan seems pretty inefficient though. Do you have any better
suggestions
for a coded solution.
--
Thanks in advance,
MarkN


"Cindy M." wrote:

Hi Mark,

Is there a way to copy a large, multi-sectioned document without
copying the
headers and footers?

Not in one step, no. The header/footer information (along with margin
settings,
number of columns) is stored "in" the section break. So you'd have to
copy each
section without the section break.

Cindy Meister
INTER-Solutions, Switzerland
http://homepage.swissonline.ch/cindymeister (last update Jun 17 2005)
http://www.word.mvps.org

This reply is posted in the Newsgroup; please post any follow question or
reply
in the newsgroup and not by e-mail :-)







  #6   Report Post  
Posted to microsoft.public.word.docmanagement
Stefan Blom Stefan Blom is offline
external usenet poster
 
Posts: 8,428
Default Copy everything except headers and footers

You can use File | Save As to create a new document, and then manually
clear headers and footers in the newly created document.

If you want to automate the header/footer deletion, try the following
very simple macro, which a knowledgeable programmer probably could
improve (or replace with a more efficient one):

Sub DeleteHeadersFooters()
Dim s As Section
For Each s In ActiveDocument.Sections
s.Headers(wdHeaderFooterEvenPages).Range.Delete
s.Headers(wdHeaderFooterFirstPage).Range.Delete
s.Headers(wdHeaderFooterPrimary).Range.Delete

s.Footers(wdHeaderFooterEvenPages).Range.Delete
s.Footers(wdHeaderFooterFirstPage).Range.Delete
s.Footers(wdHeaderFooterPrimary).Range.Delete
Next s
End Sub

--
Stefan Blom
Microsoft Word MVP


"MarkN" wrote in message
...
Hello,

Is there a way to copy a large, multi-sectioned document without

copying the
headers and footers?
--
Thanks,
MarkN












Reply
Thread Tools
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
How can I copy entire pages including Headers and Footers rfdsmith Microsoft Word Help 3 May 5th 23 08:50 PM
Copy a Word letter complete with headers and footers to Outlook Art K Microsoft Word Help 6 May 21st 06 04:26 AM
Headers and footers printing different size on odd and even pages Colinhp Microsoft Word Help 4 January 19th 06 07:55 AM
Problems with Heades and Footers Lawrin Walker Microsoft Word Help 0 September 14th 05 06:06 PM
Doc Template & headers and footers Linda G Microsoft Word Help 2 June 17th 05 11:42 PM


All times are GMT +1. The time now is 08:33 AM.

Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 Microsoft Office Word Forum - WordBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Word"