pyExcelerator - Can I read and modify an existing Excel-WorkBook?
Yes indeed, pyExcelerator does support reading data from excel spreadsheets. An example of how to do this is included in the file xls2csv-gerry.py under the directory ... pyExcelerator/examples/tools Syntax is pretty straight forward. extract_all = parse_xls(filename, CP = None) where CP is the encoding format used within tht file. Uses same codes that xlrd uses, ie 'cp437' = US English. All you need is the "parse_xls" command and simply let it iterate through your spreadsheet file. EXAMPLE: fname = "D:\\Directory\\myfile.xls"# an example filename for sheet_name, values in parse_xls(fname ): # parse_xls(arg) -- default encoding print " name of sheet is = ", sheet_name, Alternatively you can extract everything in one go... extract_all = parse_xls(fname) -- http://mail.python.org/mailman/listinfo/python-list
Is there a way to "link" a python program from several files?
Take a look at Fred Lundh's Squeeze programme. quote ... " If all you need is to wrap up a couple of Python scripts and modules into a single file, Squeeze might be what you need. The squeeze utility can be used to distribute a complete Python application as one or two files, and run it using a standard Python interpreter kit. squeeze compiles all Python modules used by the application (except for the standard library files), and packs them all in a single, usually compressed “bytecode package”. The import statement is then modified (using the ihooks module) to look in the package before searching for modules on the disk. You can also put arbitrary data files in the package, and access them via the __main__ module. ..." -- http://mail.python.org/mailman/listinfo/python-list