Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- Sub ExampleGetData()
- Dim Data As DataObject
- Set Data = New DataObject
- Data.GetFromClipboard
- MsgBox Data.GetText(x)
- End Sub
- Dim MyData as DataObject
- Private Sub CommandButton1_Click()
- 'Need to select text before copying it to Clipboard
- TextBox1.SelStart = 0
- TextBox1.SelLength = TextBox1.TextLength
- TextBox1.Copy
- MyData.GetFromClipboard
- TextBox2.Text = MyData.GetText(1)
- End Sub
- Private Sub UserForm_Initialize()
- Set MyData = New DataObject
- TextBox1.Text = "Move this data to the " _
- & "Clipboard, to a DataObject, then to "
- & "TextBox2!"
- End Sub
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement