Changing the Zoom level of the attached xlsx does not have an effect:
var workbook = new Workbook(“Zoom.xlsx”);
Worksheet ws = workbook.Worksheets;
ws.Zoom = 85; // Zoom is changed from 50 to 85
workbook.Worksheets.ActiveSheetIndex = 0;
When opening the ZoomChanges.xlsx, the chart defaults to fit the window.
Edit: As a side-note, is there a way to set the Zoom level to ‘Fit selection’ like in Excel from within Aspose?
Thank you for contacting Aspose support.
We have evaluated your presented scenario on our end while using the latest version of Aspose.Cells for .NET 184.108.40.206, and we are able to replicate the said problem. The zoom factor set for the Chart type worksheet does not seem to take effect, instead the worksheet fits it self according to the window size. We have logged an investigative ticket CELLSNET-43270 to look further into this matter. Please spare us little time to properly analyze the scenario to assist you further in this regard. In the meanwhile, we will keep you posted with updates in this regard.
Thanks for your using Aspose.Cells.
Please download and try the latest fix: Aspose.Cells for .NET v220.127.116.11 and let us know your feedback.
The latest fix does not seem to change anything for me. The chart is still to the maximum window size when opening the output file.
Thank you for writing back,
I have re-evaluated your presented scenario while using the latest version of Aspose.Cells for .NET 18.104.22.168 (link shared in Shakeel’s post) and I am unable to replicate the problem any more. I have used the code snippet and sample spreadsheet provided in your original post. The resultant spreadsheet has the specified zoom set, and it does not change while changing the windows size on Excel 2013. Attached is the resultant spreadsheet for your reference.
Please confirm that you are using the v22.214.171.124 by displaying the API version.
I am sorry, you are right it is working with the new version.
I am not quite sure what happened, I must have forgotten to recompile the test code after I changed to the latest version.
It is good to know that you are up & running again. Please feel free to contact us back in case you need our further assistance with Aspose APIs.