Re: [python-win32] MSWord: Server Busy
by Fabricio Guzman other posts by this author
Sep 30 2004 4:24PM messages near this date
[python-win32] MSWord: Server Busy
|
RE: [python-win32] MSWord: Server Busy
How about trapping the error with a try block:
bWorked = false
while bWorked == false
try
wordApp.ActiveDocument.PageSetup.TopMargin = 5
bWorked = true
catch
it's not pretty but it will try and try until the
server is finished initializing.
-Fabricio
--- Bill Papadopoulos <b_papadopoulos@[...].gr> wrote:
>
> >>Hi !
>
> >>"server busy" c'est souvent du au temps de
> lancement de ms-word
> >> "server busy" it's often because ms-word is slow
> to begin to run.
> >>Ajoute/Add "time.sleep(5)"
> >>Michel Claveau
>
>
> Hello Michael and thank your for responding,
>
> This is what I do before I get the "Server Busy"
> message:
>
> #Setting TopMargin
> wordApp.ActiveDocument.PageSetup.TopMargin = 5
>
> where wordApp is my Dispatch object.
>
>
> I 've already tried time.sleep() after setting the
> Margin which resulted
> to a "server busy" message and then the script
> "slept".
>
> Also, I tried time.sleep() before setting the Margin
> which resulted
> to make the script wait and then to get the "server
> busy" message.
>
> I need something like:
>
> while waiting for margin to be set:
> time.sleep()
>
> Any suggestions?
> Anyway, thanks again!
>
>
> Vax
> ____________________
> b_papadopoulos@[...].gr
> vax@[...].gr
>
>
>
> > _______________________________________________
> Python-win32 mailing list
> Python-win32@[...].org
> http://mail.python.org/mailman/listinfo/python-win32
>
__________________________________
Do you Yahoo!?
New and Improved Yahoo! Mail - 100MB free storage!
http://promotions.yahoo.com/new_mail
_______________________________________________
Python-win32 mailing list
Python-win32@[...].org
http://mail.python.org/mailman/listinfo/python-win32
Thread:
Bill Papadopoulos
Fabricio Guzman
Mark Hammond
|