patel.ankit
Posts: 2
Joined: Mon Feb 27, 2023 5:44 am

Export to xls Data Colum format issue

We are using highchart with xls export

We are facing bellow issue

Date format is change when its export
integer filed are converted to decimal
michal.f
Posts: 1114
Joined: Thu Aug 12, 2021 12:04 pm

Re: Export to xls Data Colum format issue

Hello and welcome to our forum!

Could you reproduce the issue in an online editor that I could work on? Because now it is hard to tell you what the problem is without taking a look at your code.

You can base on this demo: https://jsfiddle.net/BlackLabel/8ma5hsob/

Best regards!
Michał Filipiec
Highcharts Developer
https://blacklabel.pl/highcharts/
michal.f
Posts: 1114
Joined: Thu Aug 12, 2021 12:04 pm

Re: Export to xls Data Colum format issue

Hi,

The x-axis type (xAxis.type) is set to 'category' by default. For the chart to handle dates correctly, you should change this property to 'datetime'.

Code: Select all

xAxis: {
	type: 'datetime'
},

Demo: https://jsfiddle.net/BlackLabel/nuv0wf9L/
API: https://api.highcharts.com/highcharts/xAxis.type

Let me know if you have any further questions!
Best regards!
Michał Filipiec
Highcharts Developer
https://blacklabel.pl/highcharts/

Return to “Highcharts Stock”