ASPN ActiveState Programmer Network
ActiveState
/ Home / Perl / PHP / Python / Tcl / XSLT /
/ Safari / My ASPN /
Cookbooks | Documentation | Mailing Lists | Modules | News Feeds | Products | User Groups


Recent Messages
List Archives
About the List
List Leaders
Subscription Options

View Subscriptions
Help

View by Topic
ActiveState
.NET Framework
Open Source
Perl
PHP
Python
Tcl
Web Services
XML & XSLT

View by Category
Database
General
SOAP
System Administration
Tools
User Interfaces
Web Programming
XML Programming


MyASPN >> Mail Archive >> python-win32
python-win32
[python-win32] MSWord: Server Busy
by Bill Papadopoulos other posts by this author
Sep 29 2004 11:29PM messages near this date
[python-win32] win32com, excel and wx | RE: [python-win32] XP sp2 Problem?
I do some MSWord programming -if i may call it this way- through Python. I am doing well so 
far, but the first time I set a margin to a Word document I get a "server busy" message whic
h floads away after ~15 secs. This occurs only to the first Word document that i open. If i 
open a second Word document this "server busy" message will no longer appear.

After lots of search and tests I have concluded that i must set the clsctx parameter to my D
ispatch object which I created in order for my script to wait until the Word Automation Serv
er is initialized. 

I do the Dispatch as follows:

wordApp = Dispatch("Word.Application")

But, I think i must do it like this:

wordApp = Dispatch("Word.Application", clsctx = [clsctx value] )

I have found some values that clsctx accepts (such as: CLSCTX_INPROC_HANDLER = 2 ) but when 
I set them to the Dispatch (example: Dispatch("Word.Application", clsctx = 2) I get a "No su
ch interface supported".

So, my question, is there any proper way to make my script wait until the Word Automation Se
rver is initialized to avoid getting the "Server Busy" error message?

p.s.This "Server Busy" error message only appears in Win98.

Best Regards

Vax
____________________
b_papadopoulos@[...].gr
vax@cls.gr
Attachments:
unknown1
unknown2
unknown3
unknown4


Privacy Policy | Email Opt-out | Feedback | Syndication
© ActiveState Software Inc. All rights reserved