用字节读取,如
Dim cnt As Integer = e.Port.BytesToReadIf cnt > 0 Then '缓冲区是否有数据 Dim Val(cnt - 1) As Byte e.Port.Read(val,0,cnt) Dim str As String = "" For Each s As Byte In val msgbox(s) str &= s Next msgbox(str)End If