On 12/2/22 4:25 AM, QMUL_EECS DVS wrote:
Thanks for replying. Apologies for my vague question, let me see if I
can rephrase: I want to run pywin inside an aws instance, which only
allows for command line interface.
Currently I can use pywin in my local machine, but it needs to open
Visio and Word windows. However, in the aws instance it throws an error:
‘ Traceback (most recent call last):
File "C:\Program
Files\Python37\lib\site-packages\win32com\client\dynamic.py", line 86,
in _GetGoodDispatch
IDispatch = pythoncom.connect(IDispatch)
pywintypes.com_error: (-2147221021, 'Operation unavailable', None, None)
...
File "C:\Program
Files\Python37\lib\site-packages\win32com\client\dynamic.py", line 89,
in _GetGoodDispatch
IDispatch, None, clsctx, pythoncom.IID_IDispatch
pywintypes.com_error: (-2147024891, 'Access is denied.', None, None)’
Is it related to the fact that I can’t open Visio/ Word windows? If
so, is there a way for me to avoid this error?
The first and most obvious question is, do you actually have Office and
Visio installed on your AWS instance? How did you do that without a
UI? Launching Word like this usually does not bring up a UI window
unless you specifically set "xxx.Visible = True", so I'm guessing
there's something else going on.
--
Tim Roberts,t...@probo.com
Providenza & Boekelheide, Inc.
_______________________________________________
python-win32 mailing list
python-win32@python.org
https://mail.python.org/mailman/listinfo/python-win32