PageSetup after a mailmerge with a large file

W

Walter Willemstein

Hi there, I need help with the following:

In Office XP, after a mailmerge with a large text-file
(1Mb) I cannot do anything (from Macro-code) in the new
document with ActiveDocument.PageSetup.
But when I split the text-file in two smaller files I can
(with both parts).

For example I cannot set
ActiveDocument.PageSetup.FirstPageTray =
wdPrinterAutomaticSheetFeed.

When I ask the value of the properties of
ActiveDocument.PageSetup (with the large MailMerge) they
all return " 9999999", whereas the properties with the
smaller MailMerge return the right values and I can set
them to other values.

When I try to change the values by hand in the document
itself, I can change them -after the warning that the
margins aren't wright. But this also happens with the
smaller merges.

It seems that Office XP after a large MailMerge is unable
to change the PageSetup setting from code.
Or is it the printer driver that can't handle it?

Any answer to help me, I appreciate.

Thanx, WW (Holland).
 
C

Cindy M -WordMVP-

Hi Walter,

Yes, I recongize this. For some reason, Word isn't able to
set page settings for the ActiveDocument when the file is
very large (contains lots of sections). I believe there's
even a number (like 64 or 128 or something) where this kicks
in.

The solution is to use this kind of construction:
For each sec in ActiveDocument.Sections
sec.PageSetup
Next
In Office XP, after a mailmerge with a large text-file
(1Mb) I cannot do anything (from Macro-code) in the new
document with ActiveDocument.PageSetup.
But when I split the text-file in two smaller files I can
(with both parts).

For example I cannot set
ActiveDocument.PageSetup.FirstPageTray =
wdPrinterAutomaticSheetFeed.

When I ask the value of the properties of
ActiveDocument.PageSetup (with the large MailMerge) they
all return " 9999999", whereas the properties with the
smaller MailMerge return the right values and I can set
them to other values.

Cindy Meister
INTER-Solutions, Switzerland
http://homepage.swissonline.ch/cindymeister (last update Sep
30 2003)
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
:)
 
G

Guest

Hi Cindy,

Your reply really helped me! Thanx!!!
Come to thing of it, my destination file has indeed a lot
of sections. My problem is fixed.

Thanx once again!

Bye,
Walter.
 

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