Row Auto Height

Topics: Developer Forum, User Forum
Aug 13, 2008 at 2:31 PM
I am trying to see if there is a way to set a row to have it's height auto "streched" to the value of the tallest cell (usually wrapped text).  And this works for a value that is put in 1 cell, but if the text-wrapped value is in merged cells, it will not auto "stretch" the height.  This seems to be a limitation of Excel rather than PHPExcel.  I had an idea to set a value of a single cell to the same value to retrieve the height and then statically set it before writing the file, but it seems that the getRowHeight() function only retrieves the height that is set explicitly, as opposed to the actual height of the row once the value is inputted.

Any ideas?

Aug 14, 2008 at 6:10 PM
Yeah... this is weird. Unless there is a good reason why MS Office Excel does what it does then I would say that this ”limitation” is a bug. For comparison, this does not happen in OpenOffice 2.4.1

I haven't looked so much into this, but ”Allen Wyatt' Excel Tips” suggests using the identity formula put in some distant location pointing to the merged cell. Not really beautiful, but could this be a workaround?