Skip to Content
Meniu
Trebuie să fiți înregistrat pentru a interacționa cu comunitatea.
Această întrebare a fost marcată
2 Răspunsuri
5502 Vizualizări

Hello,

I want to write current datetime in excel report using pythons xlwt package.

But it shows the time in UTC format rather than my local timezone. So please help me to solve this problem.

Thanks in advance for your help!!!

Imagine profil
Abandonează
Cel mai bun răspuns

Hello Jinesh

you can use below code for get current datetime in excel report.


datetime.strftime(datetime.now(), "%d-%m-%Y")

Imagine profil
Abandonează
Cel mai bun răspuns
sheet.write(3, 1, str(date.today()))

Imagine profil
Abandonează
Related Posts Răspunsuri Vizualizări Activitate
2
iun. 23
4266
2
mar. 17
4541
3
iun. 25
7980
0
apr. 24
1741
4
nov. 23
5758