PyUNO connection to OpenOffice

Enrique Castro ecastro at dbbf.ulpgc.es
Tue Jun 10 07:42:31 EDT 2003


Skip Montanaro wrote:
>     Enrique> c:\Archivos de programa\OpenOffice.org1.1\program>python 
>     Enrique> swriter.py
>     Enrique> Traceback (most recent call last):
>     Enrique>    File "swriter.py", line 27, in ?
>     Enrique>      smgr = resolver.resolve( 
>     Enrique> "uno:socket,host=localhost,port=2002;urp;StarOffice
>     Enrique> .ServiceManager" )
>     Enrique> __main__.com.sun.star.connection.NoConnectException: 
>     Enrique> Connector : couldn't connec
>     Enrique> t to socket (WSAECONNREFUSED, Connection refused)
> 
> It would appear that StarOffice is not listening on port 2002.  Can you
> telnet to that port?

No I can't. "telnet localhost" or "telnet 127.0.0.1" failed
After a little exploration I found "telnet service
management" under administrative tools (I am translating 
from names in spanish), and turned on the telnet service.
Now if I do
c:>telnet localhost , I do connect to 127.0.0.1
But
c:>telnet localhost:2002 (or whatever other number) fails

I know nothing about sockets but they are for connecting 
things.
Do you know a very simple introduction/tutorial?

Thanks
Enrique





More information about the Python-list mailing list