On Thu, 15 Sep 2005 15:24:52 -0400, "Cavanagh, Mike" 
<[EMAIL PROTECTED]> wrote:

>We have a couple of internal applications that are written in Python and
>have always worked with Excel 2000.
>
>We are 'upgrading' to Excel 2003 and in my pre-rollout testing, our
>applications are failing.
>
>Using the testMSOffice.py test case, I receive the following:
>  
>
...

>  File "C:\Python24\Lib\site-packages\win32com\test\testMSOffice.py", line
>96, in TextExcel
>    xl.Workbooks().Add()
>  File "C:\Python24\Lib\site-packages\win32com\client\dynamic.py", line 165,
>in __call__
>    return
>self._get_good_object_(self._oleobj_.Invoke(*allArgs),self._olerepr_.
>defaultDispatchName,None)
>com_error: (-2147352562, 'Invalid number of parameters.', None, None)
>
>I'm beginning to pull my hair out here, any help would be appreciated.
>

Remove the inner set of parentheses:
    xl.Workbooks.Add()

Workbooks is a collection object, not a method.

-- 
Tim Roberts, [EMAIL PROTECTED]
Providenza & Boekelheide, Inc.

_______________________________________________
Python-win32 mailing list
Python-win32@python.org
http://mail.python.org/mailman/listinfo/python-win32

Reply via email to