[python-win32] Excel sort error with Python 2.2.3 & early binding

2006-12-19 Thread Charlton, Craig A Ctr SMC/ISA
I am using Python 2.2.3 with Pywin32-210.win32-py2.2 The following Python sequence works fine when using the 'late binding' method. import win32com.client.dynamic import types xlApp = win32com.client.Dispatch("Excel.Application") xlBook = xlApp.Workbooks.Open( 'C:\\TestExcel.xls' ) sheet = xlBook.

[python-win32] Re: Excel sort error with Python 2.2.3 & early binding

2006-12-19 Thread Roger Upole
I think the problem is with the default value for the keys that aren't specified. This works with both early and late binding: rangeToSort.Sort( Key1=sheet.Columns( 3 ), Order1=1 , Header=1, Key2=pythoncom.Missing, Key3=pythoncom.Missing ) Roger __

Re: [python-win32] Excel sort error with Python 2.2.3 & earlybinding

2006-12-19 Thread Charlton, Craig A Ctr SMC/ISA
I ran my test with the 'optional' arguments defined as pythoncom.Missing and it does work now. Previously my code was working under a very old Python 1.5.2 where the 'defaultNamedNotOptArg' was defined as pythoncom.Missing in the .py file generated for the Excel 11.0 Object Library. Evidently the

[python-win32] PYTHONPATH and .pth files under Windows XP

2006-12-19 Thread Chris Rock
PYTHONPATH and .pth files under Windows XP No matter what my PYTHONPATH is set to as a Enivorment Variable under Windows XP, the only time a .pth file is actually being read and used is when I dump it into my site-packages directory off my install location. lets say I have the following directo

Re: [python-win32] PYTHONPATH and .pth files under Windows XP

2006-12-19 Thread Mark Hammond
> PYTHONPATH and .pth files under Windows XP > > No matter what my PYTHONPATH is set to as a Enivorment > Variable under Windows XP, the only time a .pth file is > actually being read and used is when I dump it into my > site-packages directory off my install location. A quick scan of http://docs.