下你所需,载你所想!
汇集开发技术源码资料

USB操作模块基于启发在原版本上修改而来的

:40.043KB :1 :2019-11-21 16:36:24

部分简介

更新模块如下:

1、更名取[取U盘盘符列表]为[取移动磁盘盘符列表]。

2、修复了原来[取U盘盘符列表]功能,

修改常量[硬盘驱动器]为[所有驱动器]

作者的疏忽(无法完全取出所有移动盘符的问题)。

3、将返回“文本型”数据改为了返回“文本型数组”数据。

感谢启发前辈编写的模块,功能很强大。

参_线程数据.设备实例 = 参_设备信息数据.设备实例
整_线程句柄 = DLL_CreateThread (0, 65536, &移除U盘, 取指针地址 (参_线程数据), 0, 0)
.如果 (参整_执行方式 = #立即返回)
整_返回值 = 整_线程句柄
.否则
DLL_WaitForSingleObject (整_线程句柄, #永远等待)
DLL_GetExitCodeThread (整_线程句柄, 整_返回值)
关闭句柄 (整_线程句柄)
.如果结束
返回 (整_返回值)
' 备注:
' 否决类型及说明:[我懒得翻译了,自己看吧]
' 参整_否决类型=PNP_VetoTypeUnknown=0
' The specified operation was rejected for an unknown reason.
' PNP_VetoLegacyDevice=1
' The device does not support the specified PnP operation.
' PNP_VetoPendingClose=2
' The specified operation cannot be completed because of a pending close operation.
' PNP_VetoWindowsApp=3
' A Microsoft Win32 application vetoed the specified operation.
' PNP_VetoWindowsService=4
' A Win32 service vetoed the specified operation.
' PNP_VetoOutstandingOpen=5
' The requested operation was rejected because of outstanding open handles.
' PNP_VetoDevice=6
' The device supports the specified operation, but the device rejected the operation.
' PNP_VetoDriver=7
' The driver supports the specified operation, but the driver rejected the operation.
' PNP_VetoIllegalDeviceRequest=8
' The device does not support the specified operation.
' PNP_VetoInsufficientPower=9
' There is insufficient power to perform the requested operation.
' PNP_VetoNonDisableable=10
' The device cannot be disabled.
' PNP_VetoLegacyDriver=11
' The driver does not support the specified PnP operation.
' 参文_否决名缓存的返回值会根据参整_否决类型的不同而不同

USB操作模块基于启发在原版本上修改而来的

热门推荐

相关文章