Tags: actions, excel, insert, materials, microsoft, msdn, paragraph, preformated, software, standardized, text

How do I insert a preformated paragraph into a comment?

On Microsoft » Microsoft Excel

1,482 words with 1 Comments; publish: Fri, 23 May 2008 05:12:00 GMT; (30646.88, « »)

Hi,

I would like to insert a standardized paragraph into a comment.

The text would be something like:

"Work: (actions)

Part: (materials)

Data: (information used in calculations)"

Consider the following code:

If ct Is Nothing Then

ActiveCell.AddComment

Set ct = ActiveCell.Comment

'text

ct.Text "Work: (actions){enter}Part: (materials){enter}Data:

(information used in calculations)"

End If

Obviously {enter} is not working to add the carriage return that I am

looking for.

Thanks!

Mark

All Comments

Leave a comment...

  • 1 Comments
    • "Text1" & variableText & vbcrlf & .....

      "Text1" & variableText & chr(10) & .....

      --

      steveB

      Remove "AYN" from email to respond

      "Mark" <Mark.excel.todaysummary.com.discussions.microsoft.com> wrote in message

      news:93CE8721-1E10-44E1-A805-D3C3D4526EE1.excel.todaysummary.com.microsoft.com...

      > Hi,

      > I would like to insert a standardized paragraph into a comment.

      > The text would be something like:

      > "Work: (actions)

      > Part: (materials)

      > Data: (information used in calculations)"

      > Consider the following code:

      > If ct Is Nothing Then

      > ActiveCell.AddComment

      > Set ct = ActiveCell.Comment

      > 'text

      > ct.Text "Work: (actions){enter}Part: (materials){enter}Data:

      > (information used in calculations)"

      > End If

      > Obviously {enter} is not working to add the carriage return that I am

      > looking for.

      > Thanks!

      > Mark

      #1; Fri, 23 May 2008 05:13:00 GMT