Private Function DoesClipboardContainExcelCells() As Boolean Dim data As IO.MemoryStream = DirectCast(Clipboard.GetData("Link"), IO.MemoryStream) If data Is Nothing Then Return False End If Using reader As New IO.StreamReader(data) Dim linkText As String = reader.ReadToEnd If linkText.StartsWith("Excel") Then Return True End If End Using Return False End Function