Home |
Search |
Today's Posts |
#1
Posted to microsoft.public.word.docmanagement
|
|||
|
|||
Command Failure
I receive a message "Command Failure" each time I attemp to use the following
code to close a document: On Error GoTo errorHandler ActiveDocument.Close _ SaveChanges:=wdPromptToSaveChanges, _ OriginalFormat:=wdPromptUser errorHandler: If Err = 4198 Then MsgBox "Document was not closed" The code without the error handler under debug gives a "Command Failure" message. |
#2
Posted to microsoft.public.word.docmanagement
|
|||
|
|||
Command Failure
Hi ?B?bGhj?=,
I receive a message "Command Failure" each time I attemp to use the following code to close a document: On Error GoTo errorHandler ActiveDocument.Close _ SaveChanges:=wdPromptToSaveChanges, _ OriginalFormat:=wdPromptUser errorHandler: If Err = 4198 Then MsgBox "Document was not closed" The code without the error handler under debug gives a "Command Failure" message. Is there a document open? If you use just ActiveDocument.Close (no parameters) does that work? 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 :-) |
Reply |
Thread Tools | |
Display Modes | |
|
|
Similar Threads | ||||
Thread | Forum | |||
Failure to merge | Mailmerge | |||
get data failure | Mailmerge | |||
Engine Failure | Mailmerge | |||
Failure to print | Microsoft Word Help | |||
Smart tag failure | Microsoft Word Help |