Dear Flexmonster Team,
We have an issue with datetime format on exporting to Excel in Flat Form. I tried both giving datePattern to global or to dataSource properties but when I exported to excel, date formats are not same with flexmonster.
Please check export to excel function on two examples below:
Thank you for writing to us.
Our team would like to confirm that
dateTimePattern properties are not considered while exporting to Excel. Such behavior is due to specifics of the way Excel formats data and difficulties while converting patterns. However, adding the possibility to set timezone while exporting is a reasonable feature.
It will be added with a minor update ETA 23 Mar.
We will notify you as soon as the new version is released.
Do not hesitate to contact us in case any additional questions on this point occur.
Thank you for your quick response.
We don’t have any trouble with formats while exporting to excel from Classic or Compact form.
Just to clarify, the issue “
dateTimePattern properties are not considered while exporting to Excel.” is only for Flat form, right?
Thank you for your feedback.
We would like to kindly explain that exporting is the same both for compact, classic, and flat form.
We can assume that the reason you can see the difference is due to the fact that the
datetime hierarchy is placed to
columns array in your report. In such a situation, it will be exported to Excel as a plain text without formatting and
datetime data type; therefore it will look the same as on the grid.
However, in case the
datetime hierarchy is placed in
measures array or appears on the flat form, it is exported with an appropriate data type (in your case, it is
datetime). It entails the necessity of converting the Flexmonster date formatting to the corresponding Excel analog.
Please see an example in order to get a deeper understanding of the difference.
We hope it helps.
Do not hesitate to contact us in case of additional questions.
We are pleased to inform you that the issue with exporting dates with timezones to Excel was fixed.
This is available in the 2.8.3 version of Flexmonster: https://www.flexmonster.com/release-notes/
You are welcome to update the component.
Here is our updating to the latest version guide for assistance: https://www.flexmonster.com/doc/updating-to-the-latest-version/
Feel free to write to us in case of questions.