我已经设为1了
With MSComm1
.InBufferSize = 5120
.CommPort = 1
.Settings = "4800,N,8,1"
.InputLen = 1
.InputMode = comInputModeText
.RThreshold = 1
end with
With MSComm1
.InBufferSize = 5120
.CommPort = 1
.Settings = "4800,N,8,1"
.InputLen = 1
.InputMode = comInputModeText
.RThreshold = 1
end with
.InBufferSize = 5120
.CommPort = 1
.Settings = "4800,N,8,1"
.InputLen = 1
.InputMode = comInputModeText
.RThreshold = 1
.PortOpen = True
If err Then
MsgBox "故障接收仪使用的端口无效 ,请另选端口 !", vbExclamation, "初始化端口失败 "
MSComm1.PortOpen = False
Exit Sub
End If
End Withform 中button1
Dim buff As Variant
buff = "22821847"
MDIForm1.MSComm1.Output = buff
to daviddivad(你真行,居然比我还快!()嘿,你要不说,我还怀疑我的程序有问题呢,非得试到明天天亮!谢谢。