Home |
Search |
Today's Posts |
|
#1
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
I am trying to set the row height using Selection.Rows.AutoFit but it does
not seem to be working when there are merged cells. Any help is appreciated. |
#2
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
That is correct. Merged cells won't autofit.
-- Regards, Tom Ogilvy "Sandy" wrote in message ... I am trying to set the row height using Selection.Rows.AutoFit but it does not seem to be working when there are merged cells. Any help is appreciated. |
#3
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
There are two basic ways to deal with the AutoFit problem with merged cells:
1) Have a single cell in the same row offscreen that is sized the same as the merged range that has a formula that refereces the value of the active cell of the merged range. Therefore, this cell always holds the same value as that entered in the merged range. Use the Worksheet SelectionChange event to force AutoFit of this cell. Since it is in the same row as the merged range, it fixes the problem. 2) Use more complex code fired by the SelectionChange event to effect the AutoFit. Regards, Greg |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
Set a minimum row height a the same time with autofit row height | New Users to Excel | |||
Row Height stopped growing and Auot-Fit Row Height does not work | Excel Discussion (Misc queries) | |||
the row height should be excatly the height of the data | Excel Discussion (Misc queries) | |||
Resizing row height to dynamically fit height of text box | Excel Discussion (Misc queries) | |||
Set new row height based on current height | Excel Programming |