View Single Post
  #3   Report Post  
Posted to microsoft.public.excel.programming
[email protected] itsthedude@gmail.com is offline
external usenet poster
 
Posts: 14
Default Copy variable to clipboard

On Jan 7, 4:33 pm, Greg Glynn wrote:
Is there a better way to copy the contents of a variable into the
clipboard (other than, as below, copy it to a temporary cell)

MyString = "Put this in to the clipboard"
Range("A100") = MyString
Range("A100").Copy
Range("A100").ClearContents

Regards

Greg


Dim mystring As New DataObject


If usf_Convert.tbo_Number_is < "" Then

number_is.SetText usf_Convert.tbo_Number_is
number_is.PutInClipboard
End If