ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   Selection.EntireRow.AutoFit (https://www.excelbanter.com/excel-programming/409515-selection-entirerow-autofit.html)

al

Selection.EntireRow.AutoFit
 
XL2003 on XP

Selection.EntireRow.AutoFit

When I use this with most rows, it does what I expect. However, if the row
has merged cells with wrap text on and an entry long enough to cause it to
wrap, this line causes the row height to shrink to the default? of 12.75.
Does anyone have an explanation or a workaround?

--
Al C

Dave Peterson

Selection.EntireRow.AutoFit
 
That's one of the problems with merged cells.

Jim Rech wrote a macro called AutoFitMergedCellRowHeight that you may like:
http://groups.google.com/groups?thre...%40tkmsftngp05



Al wrote:

XL2003 on XP

Selection.EntireRow.AutoFit

When I use this with most rows, it does what I expect. However, if the row
has merged cells with wrap text on and an entry long enough to cause it to
wrap, this line causes the row height to shrink to the default? of 12.75.
Does anyone have an explanation or a workaround?

--
Al C


--

Dave Peterson

al

Selection.EntireRow.AutoFit
 
Thank you, Dave
--
Al C


"Dave Peterson" wrote:

That's one of the problems with merged cells.

Jim Rech wrote a macro called AutoFitMergedCellRowHeight that you may like:
http://groups.google.com/groups?thre...%40tkmsftngp05



Al wrote:

XL2003 on XP

Selection.EntireRow.AutoFit

When I use this with most rows, it does what I expect. However, if the row
has merged cells with wrap text on and an entry long enough to cause it to
wrap, this line causes the row height to shrink to the default? of 12.75.
Does anyone have an explanation or a workaround?

--
Al C


--

Dave Peterson



All times are GMT +1. The time now is 03:47 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com