Se rendre au contenu
Menu
Cette question a été signalée
2 Réponses
5476 Vues

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!!!

Avatar
Ignorer
Meilleure réponse

Hello Jinesh

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


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

Avatar
Ignorer
Meilleure réponse
sheet.write(3, 1, str(date.today()))

Avatar
Ignorer
Publications associées Réponses Vues Activité
2
juin 23
4249
2
mars 17
4520
3
juin 25
7963
0
avr. 24
1724
4
nov. 23
5734