2003: Autofit merged cells

  • Thread starter Thread starter David M. Marcovitz
  • Start date Start date
D

David M. Marcovitz

I am using Excel 2003. I need to merge the cells in most of columns C
and D (e.g. C2 is merged with D2, C3 is merged with E3, etc.). Merging
is not a problem. I also need to wrap text in those newly merged cells.
That is not a problem. The problem arises when I try to autofit the text
in the merged and wrapped cells. Any attempt to autofit cuts off the
cells at one line of text. If I remove the merging, the autofit works
perfectly.

For example, if the merged C2&D2 contains:

This is my comment to you. You
are doing very well. I hope that
you continue to do this well on
the rest of your assignments.

Autofit will shrink the height of the line to just show:

This is my comment to you. You

Is there anything that I can do about this? It is possible to redesign
the worksheet so that the cells are not merged, but this is a pain and
produces results that are not quite what is needed. Please help. Thanks.

--David
 
Yes, merged cells cause plenty of grief, it's typically recommended here
to not use them.
 
David

If cells are merged. the row will not autofit even with wrap text enabled
without using VBA

See google search thread for code by Greg Wilson

http://groups.google.com/group/micr...60cbeb27874?lnk=st&q=&rnum=4#ca1c160cbeb27874

Second piece of advice is.............get rid of the merged cells.

They cause no end of problems with copying, pasting, sorting, filtering,
autofitting and a few(many?) others that have slipped my mind at present.


Gord Dibben MS Excel MVP
 
Actually in most cases you can make the sheet look like it has merged cells,
Assume you want a 5 column header, type the header in the leftmost
cell of those 5, then select all 5 cells and then do format>cells>alignment
and from the
horizontal text alignment dropdown select "Center across selection"

I agree with Bob, I even wish they would remove the option
of having merged cells. If you have to audit and redesign spreadsheets
with lots of merged cells then you tend to look upon them
as the Devil's spawn


--


Regards,


Peo Sjoblom
 
Back
Top