copying to the clipboard

  • Thread starter Thread starter greg
  • Start date Start date
G

greg

This should be easy.
I want to select a cell. then copy the comment from a cell into the
clipboard.

To get the comment I can
Excel.Selection.Comment.Text


for copying to the clipboard. Googline I see a clipboard object. people
use:
Clipboard.setText

but clipboard is not an object for me.
Do you have to add a reference in?
dim it as something?

thanks
 
Hi

You can not copy a comment into the clip board, but you can work with it
like this:

Sub test()
Dim sComm As String
sComm = Selection.Comment.Text
With Worksheets(1).Range("B1").AddComment
.Visible = False
.Text sComm
End With
End Sub

Regards,
Per
 
Back
Top