Column width for calculated cells

Hi,


We are using method AutoFitColumns() of Aspose.Cells.Worksheet to set width of columns automatically and my question is, whether it is possible to set proper column width for calculated cell(s) (cells with formula).

Thanks,
Lukáš Toldy

Hi,


Thanks for your query.

I think you should call Workbook.CalculateFormula() method first (so the formulas get calculated in the spreadsheet) and then use Worksheet.AutoFitColumn(s) method to auto-fit column(s) data accordingly.

Let us know if I can be of any further help.

Thank you.

Hi,


thanks for reply. Now it works as I intended. I really appreciate your quick response.

Many thanks,
Lukáš Toldy

Hi,


Thanks for your feedback.

Good to know that it figures out your issue now. Feel free to contact us any time if you need further help or have some other issue or queries, we will be happy to assist you soon.

Thank you.