How to open and repair without Show Repairs Dialog

T

Tom G.

I am using C# to write a Windows Service application that constantly
converts Word Documents to XML for further processing. I have everything
working great except when the document is corrupt and requires "Open and
Repair". I can call the Open method with OpenAndRepair set to true, but the
darn "Show Repairs" dialog causes my application to hang because no user
intervention. If I click close on the Show Repairs dialog, the application
goes on its merry way.

Any suggestions?

Thanks,

Tom Grant
 
J

Jean-Guy Marcil

Bonjour,

Dans son message, < Tom G. > écrivait :
In this message, < Tom G. > wrote:

|| I am using C# to write a Windows Service application that constantly
|| converts Word Documents to XML for further processing. I have everything
|| working great except when the document is corrupt and requires "Open and
|| Repair". I can call the Open method with OpenAndRepair set to true, but
the
|| darn "Show Repairs" dialog causes my application to hang because no user
|| intervention. If I click close on the Show Repairs dialog, the
application
|| goes on its merry way.
||

Have you tried
Application.DisplayAlerts = wdAlertsNone
?
This will cause some (SOME being the key word here!) message not to be
displayed and Word will use the message box's default response.
Don't forget to reset it to
Application.DisplayAlerts = wdAlertsAll
when you are done.

--
Salut!
_______________________________________
Jean-Guy Marcil - Word MVP
(e-mail address removed)
Word MVP site: http://www.word.mvps.org
 
H

Helmut Weber

Hi Tom,
just a vague idea. There is a util called "clickyes",
that clicks "yes" to outlook's question, whether you
want to allow programmatically sending mails.
Seems to be a similar problem.
 

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