Hi Andreas,
1) What is the value of wdDoNotSaveChanges at this point in your code?
It needs to be 0 or False (I find it easier just to pass True or False
in this argument rather than try to remember the names of the Word
constants).
2) If that's not the answer, is it possible that something you've done
has created another document, or modified a template, without your
noticing?
>Hi!
>
[quoted text clipped - 11 lines]
>Best regards,
>Andreas
--
John Nurick [Microsoft Access MVP]
Please respond in the newgroup and not by email.
hufflehuffle@west.de - 03 Feb 2006 07:53 GMT
John Nurick schrieb:
> Hi Andreas,
Hi, John,
thanks for your answer.
> 1) What is the value of wdDoNotSaveChanges at this point in your code?
> It needs to be 0 or False
It actually is 0.
> (I find it easier just to pass True or False
> in this argument rather than try to remember the names of the Word
> constants).
I have been advised to use predefined constant names since the
beginning of my programming in any language, just to cover future
changes... Is this wring?
> 2) If that's not the answer, is it possible that something you've done
> has created another document, or modified a template, without your
> noticing?
The target of that serial letter is set to "New Document", so a second
document is created in the process. Then the macro tries to close the
template to prevent the user from messing around with it. There the
request for a filename occurs.
Should'nt wdDoNotSaveChanges prevent this request even _if_ a macro
changed the template in the process?
Best regards,
Andreas