Page tree

Welcome to FreeSoftwareServers Confluence Wiki

Skip to end of metadata
Go to start of metadata
Public ClipboardStrNewLineArr() As String
Public Function GetClipboardStr() As String
 Dim Clipboard As MsForms.DataObject
 Set Clipboard = New MsForms.DataObject
 GetClipboardStr = Clipboard.GetText(1)
End Function
Public Sub GetClipboardStrNewLineArr()
 Dim ClipBoardStr As String
 ClipBoardStr = GetClipboardStr
 ClipboardStrNewLineArr() = Split(ClipBoardStr, vbNewLine)
End Sub
Sub TestIng()
 Call GetClipboardStrNewLineArr
 For i = 0 To UBound(ClipboardStrNewLineArr)
  Debug.Print "NewLine # = " & i
  Debug.Print ClipboardStrNewLineArr(i)
End Sub
  • No labels