Open GoogleCodeExporter opened 9 years ago
当在向Com发送指令时,如果没有返回结果,程序会一直处在�� �环之中,这样显然不行。 解决办法:应该在等待返回结果时添加超时检查。 //接收数据 循环读取数据 直至收到“OK”或“ERROR” try { string temp = string.Empty; while (temp.Trim() != "OK" && temp.Trim() != "ERROR") { //××××××××这里 temp = _com.ReadLine(); result += temp; } return result; } 我已经做过修改,可以更新吗?
Original issue reported on code.google.com by wenhua1...@gmail.com on 19 Oct 2011 at 2:51
wenhua1...@gmail.com
求超时部分的代码
Original comment by doyle...@gmail.com on 20 Feb 2012 at 5:32
doyle...@gmail.com
超时的问题比较多啊,连续发送三四十条就超时失败
Original comment by majun2r...@gmail.com on 24 Oct 2012 at 7:56
majun2r...@gmail.com
Original issue reported on code.google.com by
wenhua1...@gmail.com
on 19 Oct 2011 at 2:51