Posts in the Python Category at myL10N.net

Automating Excel with Python

February 6, 2011
by olivier

Post to Twitter Post to Yahoo Buzz Post to Google Buzz Post to LinkedIn Post to MySpace Post to Technorati

Like PERL, Python is also commonly used to perform engineering tasks or to build more complex software.

If your company programming history is more Python oriented, it might be interesting to know how to use Python to pilot Excel or other application that are exposing a OLE object.

Here is an example of a Python script that calls Excel

import win32com.client
    excel = win32com.client.Dispatch('Excel.Application')
    excel.Workbooks.open(ficXls)
    #parcours de la zone de données
for li in zoneLi:
        Coord=[]
        Coord.append(id)
        id=id+1
        for col in zoneCol:
            valeur=excel.ActiveSheet.Cells(li,col).Value
             Coord.append(valeur)

Using Python for your engineering work

February 6, 2011
by olivier

Post to Twitter Post to Yahoo Buzz Post to Google Buzz Post to LinkedIn Post to MySpace Post to Technorati

In this post category, I will add the different codes that I know when you use Python for your enginerring work or for your development tools.

myL10N.net | Terms and Conditions
© 2007-2011 - myL10N.net All rights reserved