Free Support Forum - aspose.com

Autosize column?

Is there away that I can reproduce through code the same autosize accomplished by double clicking the column header limit?

Hi,

Currently the control doesn't implement this. We will add such an api soon.

Thank you for considering Aspose.

BUMP

What is the status on this please?

I was looking to switch out the Syncfusion grid in an application with your grid, am testing at the moment, but it still doesn't look to have a column autosize function.

i cuurently use code as follows on the syncfusion grid to auto-resize a column - and I need to have the same functionality in a replacement grid control before switching:

gridControl.ColWidths.ResizeToFit(range, GridResizeToFitOptions.IncludeHeaders);

Please advise,

Regards, G.

Hi,

Sorry for the delay. We are doing some urgent updates currently. I think we can provide a new hotfix that implement this api within 2 weeks. Thank you for considering our product and being patient.

Hi,

The attachment is the new hotfix 1.9.4.4. A new client side function

resizeColumnToFit is added.

usage: resizeColumnToFit(columnIndex, includeColumnHeader);

example:

function resizeToFit()

{

GridWeb1.resizeColumnToFit(3, true);

}