norseman <[EMAIL PROTECTED]> wrote: > >I'm only talking about IPC related. >I have googled, yahooed, and so forth for several months now. ALL >examples I've come across have failed including those pertinent in the >Python doc area. > >Outline: > cd somedir > ls -1 *.xls >thislist #ls hyphen one > python process.py > (yes - ls can go here if wanted. easier to edit outside) > open thislist > loop until done > start excel (or scalc) > have it open file > have it save file as a .csv (or .dbf) > close excell (or scalc) > >Would seem to be a trivial exercise.
Excel is a COM-driven application. You have to drive it through the object model. import win32com.client excel = win32com.client.Dispatch( 'Excel.Application' ) xlCSV = 6 ... for nm in list_of_file_names: csv = os.path.splitext( nm )[0] + '.csv' wb = excel.Workbooks.Open( nm ) wb.SaveAs( csv, xlCSV ) wb.Close() If you want to watch the progress, add "excel.Visible=1" after the dispatch. -- Tim Roberts, [EMAIL PROTECTED] Providenza & Boekelheide, Inc. -- http://mail.python.org/mailman/listinfo/python-list