LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #1   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 28
Default Re-sizing C. Boxes using Debra Dalgleish

Hi. Excel 2003

3 questions

1. I have about 300 comment boxes to format. I just need to make them all
the same size. I'm not worried about anything else.

Debra's code should work, but it makes them about .3" inches by .3" inches.

Can anyone help me adapt her code to make my boxes 1.8" tall by 1.5" wide.

Here is her code:

Sub ResizeCommentsInSelection()
'Posted by Dave Peterson 2002-02-25
Dim mycell As Range
Dim myRng As Range
Dim lArea As Long

Set myRng = Selection

For Each mycell In myRng.Cells
If Not (mycell.Comment Is Nothing) Then
With mycell.Comment
.Shape.TextFrame.AutoSize = True
If .Shape.Width 300 Then
lArea = .Shape.Width * .Shape.Height
.Shape.Width = 200
.Shape.Height = (lArea / 200) * 1.2
End If
End With
End If
Next mycell
End Sub




2. How do I enter the code?

I assume I right click on the sheet tab,select view code, copy and paste.

Then do I need to click run or do I just save the code to my spreadsheet and
it will take care of itself.

3. I would imagine that I need to make sure that all cells are unlocked?

Thanks in advance
--
vze2mss6
 
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Debra Dalgleish Question VBA Noob Excel Worksheet Functions 7 November 9th 06 10:40 PM
Bless you, Debra Dalgleish & Pejo Sjoblom! [email protected] Excel Worksheet Functions 5 June 5th 06 02:46 PM
Debra Dalgleish nc Excel Discussion (Misc queries) 14 May 12th 06 12:41 PM
Debra Dalglish nc Excel Discussion (Misc queries) 6 July 4th 05 03:57 PM
Multiple Consolidation Ranges - Debra Dalgleish nc Excel Discussion (Misc queries) 1 April 27th 05 09:01 PM


All times are GMT +1. The time now is 06:01 AM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"