win32 problem interacting with word97

Chin Huang cthuang at vex.net
Wed Mar 27 19:45:03 EST 2002


In article <Xns91DE7E01D2955andrewdarwinwarscom at 62.253.162.103>,
Andrew Brown  <killspam at darwinwars.com> wrote:
>I am trying to convert a couple of hundred MS word 97  files to html, and 
>then reformat them into a template. 
>
>Mostly, this works, but there are some which contain accented letters, 
>and the Word html converter barfs on these in a peculiarly irritating 
>way: it puts up a dialogue box with a message saying 
>
>"This document contains characters that are not in the current language 
>encoding. To preserve them, choose cancel and select the appropriate 
>language encoding. For multilingual documents, use UTF-8."
>
>It is possible to press "OK" or "cancel" or any damn thing if you can see 
>the dialogue box; but my program can't see it, and goes on trying to get 
>word to process the next file until, after about 30 seconds python 
>crashes completely. Only then do I see the dialogue box which has caused 
>the trouble. 

Try setting the DisplayAlerts property of the Application object to 0.
Word will not display any dialog boxes.  It will choose the default
action and continue the operation.



More information about the Python-list mailing list