Chart to image problem

@Archie000

Thanks for the runnable sample code. We were able to observe this issue and logged it in our database for investigation and for a fix. Once, the issue is resolved or we have some other news for you, we will let you know asap.

This issue has been logged as

  • CELLSJAVA-42527 - Chart has many values in x-axis and values are overlapping over each other

Hi,

Please also look into the issue of pivot table and chart showing date in different format. I am inserting data in d-mmm-yyyy format but output chart image is showing date in different format.

@Archie000

Please check the output files that were generated by your most recent code. Please check if they are OK or anything missing in them.

Output Files of Your Code.zip (154.1 KB)

Please provide MS-Word document containing the screenshots of the issues you have mentioned in your recent post. Thanks for your cooperation in this regard and have a good day.

Hi,

Yes this is the output I am getting. One chart has distortion in x-axis due to many values. Other chart are coming with wrong date format. I want them to come in d-mmm-yy format. Kindly provide solution for it.

Thanks

@Archie000

Thanks for using Aspose APIs.

We have observed this issue and logged it in our database for investigation and for a fix. Once, the issue is resolved or we have some other news for you, we will update you asap.

This issue has been logged as

  • CELLSJAVA-42530 - Pivot Tables and corresponding Charts do not have correct Date format

Hi Shakeel,

Any update on the two issues?

Thanks

@Archie000

Thanks for using Aspose APIs.

We are afraid there is no update for you at this moment regarding these issues. However, we have logged your comment in our database against these issues and requested the product team to provide some fix or ETA for these issues. Once there is some news for you, we will update you asap by posting in this topic.

@Archie000

We are working over your issues and hopefully both of them should be fixed before March 26, 2018. Once, the fix is available for you, we will let you know by posting in this topic.

@Archie000

Thanks for using Aspose APIs.

We have researched the ticket CELLSJAVA-42530 and found, it is not an issue. You want to get the correct number format via changing the number format of data source. But it is not a valid operation. If you do it in MS-Excel, you cannot get the correct result.

You should change the number format of PivotField in PiovtTable. And then refresh and calculate the PivotTable, then you will get the correct number format. Let’s take charts in the worksheet named “GI_Throughput” for instance, the sample code is as follows:

Java

Workbook wb = new Workbook(filePath + "Weekly Output.xlsx"); 

Worksheet sampleSheet = wb.getWorksheets().get("GI_Throughput"); 

PivotTableCollection pivots = sampleSheet.getPivotTables(); 

int pivotCount = pivots.getCount(); 

for (int i = 0; i < pivotCount; i++) 
{ 
	PivotTable pt = pivots.get(i); 
	pt.getBaseFields().get("SDATE").setNumberFormat("dd-MMM-yy"); 
	pt.setRefreshDataFlag(true); 
	pt.refreshData(); 
	pt.calculateData(); 
	pt.setRefreshDataFlag(false); 
} 

ChartCollection charts = sampleSheet.getCharts(); 

int chartCount = charts.getCount(); 

for (int c = 0; c < chartCount; c++) 
{ 
	Chart chart = charts.get(c); 
	chart.refreshPivotData(); 
	chart.toImage(filePath +"java_" + chart.getTitle().getText().trim() + ".png"); 
}

@Archie000,

This is to inform you that we have fixed your issue (logged earlier as “CELLSJAVA-42527”) now. We will soon provide the fix after performing QA and including other enhancements and fixes.

@Archie000

Thanks for using Aspose APIs.

Please download and try the following fix for your issue CELLSJAVA-42527 and let us know your feedback.

Hi Amjad/Shakeel,

Thank you for your help and support in the issue. Will try the suggested solution soon.

@Archie000

Sure. Please take your time in testing, hopefully your issue will be resolved with it. Please feel free to let us know if you encounter any error during testing. We will be glad to help you further.

The issues you have found earlier (filed as CELLSJAVA-42530,CELLSJAVA-42527) have been fixed in this update.


This message was posted using Notification2Forum from Downloads module by Aspose Notifier.

The issues you have found earlier (filed as CELLSJAVA-42530,CELLSJAVA-42527) have been fixed in Aspose.Cells for Java 18.4. Please also see the document for your reference:

The issues you have found earlier (filed as CELLSJAVA-42530,CELLSJAVA-42527) have been fixed in this update.


This message was posted using Notification2Forum from Downloads module by Aspose Notifier.