Warning: file_get_contents(/data/phpspider/zhask/data//catemap/8/api/5.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Api 正在打开大于9的COM端口_Api_Vb6_Serial Port - Fatal编程技术网

Api 正在打开大于9的COM端口

Api 正在打开大于9的COM端口,api,vb6,serial-port,Api,Vb6,Serial Port,我有一个VB6程序,使用commx.ocx打开端口。在COM端口大于9之前,该函数工作正常 有文章指出,使用Win32 API“createfile”时也会出现同样的问题。使用createfile时的修复方法是将“\。\COM10”作为createfile的lpFileName参数传递 我仍然想继续使用commx.ocx。如果COM大于9,有人知道如何使其工作吗?我不确定open()方法在commx.ocx上是如何工作的,但我知道它依赖于PortNumber属性,该属性是一个长数据类型,因此我无

我有一个VB6程序,使用commx.ocx打开端口。在COM端口大于9之前,该函数工作正常

有文章指出,使用Win32 API“createfile”时也会出现同样的问题。使用createfile时的修复方法是将“\。\COM10”作为createfile的lpFileName参数传递

我仍然想继续使用commx.ocx。如果COM大于9,有人知道如何使其工作吗?我不确定open()方法在commx.ocx上是如何工作的,但我知道它依赖于PortNumber属性,该属性是一个长数据类型,因此我无法传递\\


谢谢

commx.ocx
不是VB6中的本机控件。要获得使用它的帮助,你应该询问作者

或者,您可以使用VB6附带的控件,其中属性接受最多16个端口号

对于任何高于此值的端口,您都需要切换到API或其他允许它的第三方控件