Skip to main content

Python create excel

Project description

pip install easy_excel, xlwt


from python_easy_excel import Excel, Column

class A:
def __init__(self, a=’Nothing’, b=’Все хорошо’, c=43):
self.a, self.b, self.c = a, b, c

excel_example = Excel()

columns = [Column(‘a’), Column(‘b’, lambda x: x.b), Column(‘Thi is C’, lambda x: x.c)] excel_example.add_sheet(‘New sheet’, columns=columns, objects=[A(), A(b=354), A(423,12)]) excel_example.add_sheet(‘double’, columns=columns, objects=[A(b=’4233’), A(12, 12)]) excel_example.add_sheet(‘third’, columns=columns, objects=[A(), A(b=354), A(423,12)])’Новый файл’, dir=’/home/nicking/’)

Project details

Supported by

AWS AWS Cloud computing Datadog Datadog Monitoring DigiCert DigiCert EV certificate Facebook / Instagram Facebook / Instagram PSF Sponsor Fastly Fastly CDN Google Google Object Storage and Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Salesforce Salesforce PSF Sponsor Sentry Sentry Error logging StatusPage StatusPage Status page