Close document error in VBA

  • Thread starter David Schnelbaker
  • Start date
D

David Schnelbaker

Word 2003,

In a Word 2003 template document I have a macro triggered by a CheckBox
event template that opens up another document, grabs data in that second
document and then is supposed to close that second document.
When I run the macro from the VBA editor it works exactly as designed with
no errors. But when the Macro is triggered as a result of the CheckBox
status change, I get a run-time error 4198 "Command Failed" at the line that
closes the document.

The offending line is just "ActiveDocument.Close (False). I have put a
MsgBox with the describing the ActiveDocument so I know it is the right doc
that I am trying to close.

Any ideas?
 

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