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

Free Support Forum - aspose.com

Worksheet AutoFitRows() Not working


I am using Apsose.cells version to Export Data into the Excel from Data Table. Every thing is working for Except WorpWarp(Auto Fit Row) based on the Text size in the cell. Once the Data is loaded into the Sheet Object we are calling following code perform wordwrap. it is woking in local system but not in the Client Machine and also in client machine some times cell is overlapping the cell Text.

Please find the code below.

for (int nCount = StartRow; nCount < worksheet.Cells.GetLastDataRow(0) + 1; nCount++)
if (nCount >= this.nStartRow - 1)
worksheet.Cells.Rows[nCount].Height = worksheet.Cells.Rows[nCount].Height + 8;

Note: I am adding 8 in the above code just to increase the row size.

Note: We are using above because "AutoFitRows()" is not working.


Aspose.cells :

Excel : 2007/2010

Please help me in this regard.


krishna A.


Since you are using an older version of the product, so we are not sure about the issue as you mentioned. We recommend you to kindly try our latest version, e.g. v7.3.5, it should work fine regarding Auto-fit operation. If you still find the issue with v7.3.5, give us your template file(s) and runnable code, we will check your issue to figure it out (if we could find the issue).

Thank you.