Free Support Forum - aspose.com

Customize Chart Display Unit and Default Paper Size

Hello,

Recently I am using the Aspose Cell in developing a .NET program for generating an Excel report. However, I face two problems related with customization of enumerables.

The first question is related to the charts. I can write a program in generating an excel file with a bar chart. However, when I am trying to configure the display unit of value axis, I can only choose from three options: Hundreds, none and Thousands. But my boss asks me to produce the unit into a customized unit, "ten thousands" that can be found in Excel for simplified and traditional Chinese region locale. I have no idea about how to do so.

Dim po_global_chart As Chart = po_worksheet3.Charts(0)

po_global_chart.ValueAxis.DisplayUnit = DisplayUnitType.Thousands

The second question is similar to the first one, and it is related to produce a printout on a customized paper. I have to use a special paper ( 11" x 14" ) in producing my report printout. I determine that it is not a standard paper size that is supported by Windows and therefore I create it from the "Server Properties" in "Fax and Printer Option". However, I do not know how to set it as the default paper when I am using the Aspose Cells. Is there any way that I can print out this report programmatically without resetting the paper option in manual?

po_worksheet3.PageSetup.PaperSize = PaperSizeType.Paper10x14

Please help as I am a beginner in using the Aspose Cells, thanks.

Nazaa1

Hi Nazaa1,

Thanks for considering Aspose.

1). Which Aspose.Cells version you are using. Well, no there are not three options only. The latest version (4.4.1) support to set all the display units same as MS Excel of the value axis for your need. It has all the members including millions, billions and trillions etc, kindly check: http://www.aspose.com/documentation/file-format-components/aspose.cells-for-.net-and-java/aspose.cells.displayunittype.html

2). Aspose.Cells currently does not support to print documents although you may set all the pagesetup options including printing and paper settings same as MS Excel options i.e., http://www.aspose.com/documentation/file-format-components/aspose.cells-for-.net-and-java/aspose.cells.papersizetype.html, so you may set the paper size for your need.

Thank you.