Autosize for all worksheet

Topics: Developer Forum, Project Management Forum, User Forum
Nov 4, 2009 at 1:01 PM

Hi all.

In my worksheet I've a lot of column and is impossible to make

$objPHPExcel->getActiveSheet()->getColumnDimension('B')->setAutoSize(true);

for 150 column aka 150 source rows.

There's any comman to do this or other workaround?

Thank's,

Alex.

Developer
Nov 4, 2009 at 10:55 PM
umpire274 wrote:

In my worksheet I've a lot of column and is impossible to make

 

$objPHPExcel->getActiveSheet()->getColumnDimension('B')->setAutoSize(true);

for 150 column aka 150 source rows.

There's any comman to do this or other workaround?

There is no workaround at the moment, but once we get fixed this work item:

http://phpexcel.codeplex.com/WorkItem/View.aspx?WorkItemId=10861

it should be possible to use e.g. getColumnDimension('A:ET')->setAutoSize(true) to autosize each of the columns in the range A:ET.

This is what you are asking for so there is no need to raise any additional feature request.