We're sorry Aspose doesn't work properply without JavaScript enabled.

Free Support Forum - aspose.com

Column Width changes in Page Layout view

I have been setting columns’ widths assigning pixel value.

In mi Desktop using Excel 2010 looks fine in every view (Normal, Page Layout, Page Break, Print Preview)

In my laptop column widths change when I choose Page Layout view (other views and the real Printed version look great)

This is how I assign values:
worksheet.Cells.CreateRange(row, 1, 1, 2).ColumnWidth = 20;
worksheet.Cells.SetColumnWidth(3, 16.71);
worksheet.Cells.SetColumnWidth(4, 15);
worksheet.Cells.SetColumnWidth(5, 17);
worksheet.Cells.SetColumnWidth(6, 15.43);

Should I assign values represented in Inches? or only Integer pixels?
Thanks for your help

Hi,

Thanks for your posting and using Aspose.Cells.

Please provide us your simple sample winform application replicating this issue and some screenshot(s) highlighting your issue with red circles. Please also provide us the source excel file(s) used in your code and your actual and expected output excel files. You can create expected output excel file manually using Microsoft Excel. We appreciate your time and efforts spent on communicating and describing this issue in detail to us. We will also try our best to resolve your issue as soon as possible. Thanks for your cooperation.