英文:
POI Excel date-time format dependent on region
问题
我希望日期根据地区以日期时间格式进行格式化。
查看此链接,可以使用日期格式14
。这将根据地区更改格式。例如,对于英国,格式为d/m/yy
,而对于美国,格式为m/d/yy
。这仅包括日期,不包括时间。
是否可以做同样的事情,同时包括时间?
英文:
I would like dates to be formatted as date-times depending on the region.
Looking at this a date format of 14
can be used. This will make the format change depending on region. E.g. d/m/yy
for UK while m/d/yy
for US. This will only include the date and not time too.
Is it possible to do the same but to also include times?
答案1
得分: 1
你可能想要使用 0x16
(十进制为 22
)作为键:
> 0x16, "m/d/yy h:mm"
英文:
Looking at this documentation you might want to use 0x16
(22
as decimal) as key:
> 0x16, "m/d/yy h:mm"
通过集体智慧和协作来改善编程学习和解决问题的方式。致力于成为全球开发者共同参与的知识库,让每个人都能够通过互相帮助和分享经验来进步。
评论