openpyxl.utils.datetime module
Manage Excel date weirdness.
- openpyxl.utils.datetime.from_ISO8601(formatted_string)[source]
Convert from a timestamp string to a datetime object. According to 18.17.4 in the specification the following ISO 8601 formats are supported.
Dates B.1.1 and B.2.1 Times B.1.2 and B.2.2 Datetimes B.1.3 and B.2.3
There is no concept of timedeltas in the specification, but Excel writes them (in strict OOXML mode), so these are also understood.
- openpyxl.utils.datetime.from_excel(value, epoch=datetime.datetime(1899, 12, 30, 0, 0), timedelta=False)[source]
Convert Excel serial to Python datetime