![]() |
Sizing Comments
Is there a way to programmatically resize the comment
shape that is displayed? I want all of the comment to be visible without the need to Edit the comment and manually resize the shape. The ShapeRange.ScaleHeight method has a scale parameter but it does not appear that the scale can be set to auto size. Excel 2002, Win XP. TIA Tom |
Sizing Comments
Tom, I have code that will do this, but I can't get at it
until tomorrow. If noone else responds, check back tomorrow and I'll post a function here that autosizes the comment in the activecell. -----Original Message----- Is there a way to programmatically resize the comment shape that is displayed? I want all of the comment to be visible without the need to Edit the comment and manually resize the shape. The ShapeRange.ScaleHeight method has a scale parameter but it does not appear that the scale can be set to auto size. Excel 2002, Win XP. TIA Tom . |
Sizing Comments
You can use code similar to the following:
'============================ Sub AutosizeComments() Dim cmt As Comment For Each cmt In ActiveSheet.Comments cmt.Shape.TextFrame.AutoSize = True Next End Sub '========================= Tom Ulincy wrote: Is there a way to programmatically resize the comment shape that is displayed? I want all of the comment to be visible without the need to Edit the comment and manually resize the shape. The ShapeRange.ScaleHeight method has a scale parameter but it does not appear that the scale can be set to auto size. Excel 2002, Win XP. -- Debra Dalgleish Excel FAQ, Tips & Book List http://www.contextures.com/tiptech.html |
All times are GMT +1. The time now is 08:08 PM. |
Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com