Page tree

Welcome to FreeSoftwareServers Confluence Wiki

Skip to end of metadata
Go to start of metadata
Private Sub TextBox2_KeyUp(ByVal KeyCode As MSForms.ReturnInteger, ByVal Shift As Integer)
 If Shift = 2 And KeyCode = vbKeyV Then
   Debug.Print "Paste"
   TextBox2.Value = GetClipBoardAsStr
 End If
End Sub
Public Function GetClipBoardAsStr() As String
Dim clipBoard As MSForms.DataObject
Set clipBoard = New MSForms.DataObject

clipBoard.GetFromClipboard
GetClipBoardAsStr = clipBoard.GetText(1)
End Function
  • No labels