LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #1   Report Post  
Posted to microsoft.public.excel.programming
JT JT is offline
external usenet poster
 
Posts: 234
Default Aligning comments

My macro gets comments from a legacy system and builds a varaible called
"notes". The comments consist of date, time, user ID and freeform text. I
build a string with spaces between the different fields to try and line them
up because there can be 5, 10, or more comments retrieved for each item.

Once all of the comments have been retrieved from the legacy system, the
"notes" variable is pasted in a cell as an Excel comment. This part works
well; however, when the comments are displayed it looks really ragged. I
would like to try and line up the fields a little better like this:

1/15/07 2:15 PM 12345 Joe said it is okay to pay
10/07/06 3:45 AM 124AB Check should arrive any day

I once used "Courier New" as the text style in a combo box to line up
different fields and it worked really well. I am using the following code to
go back and format all of the comments on a particular sheet once all of the
comments have been pasted in Excel. However, they still aren't lining up
like I want them to.

Sub MyComments()

Dim w As Worksheet
Dim ct As Comment

For Each w In ActiveWorkbook.Worksheets

If w.Name = "My List" Then

For Each cmt In ws.Comments
With ct.Shape.TextFrame.Characters.Font
.Name = "Courier New"
.Size = 9
End With
Next ct
End If
Next w

End Sub

Is it even possible to do what I want? If so any suggestions would be
greatly appreciated. Thanks for the help.........JT

--
JT
 
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
excel 2000 how to format the comments font all comments Delquestion Excel Discussion (Misc queries) 1 October 8th 09 02:19 PM
Aligning rows. Help... Anders Excel Discussion (Misc queries) 1 August 12th 09 08:21 AM
in excel useing comments how do you add clip art to comments? dhouse New Users to Excel 2 July 18th 07 08:14 AM
Aligning decimal numers to the centre of the cell and aligning dec Ramesh Babu Excel Discussion (Misc queries) 1 July 1st 06 10:33 PM
Aligning text Louise Excel Discussion (Misc queries) 1 March 16th 05 11:49 AM


All times are GMT +1. The time now is 04:29 PM.

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"