(求助)用vb扫描磁盘文件

[复制链接]
查看11 | 回复2 | 2011-5-22 06:36:43 | 显示全部楼层 |阅读模式
为什么我用这段代码扫描出来的文件只显示前六个(不是应该显示全部文件吗)



\'scan(扫描)thecontents(内容)ofthedrivelistboxcontrol
Fori=0ToDrive1.ListCount-1
PrintDrive1.List(i)
Next

\'scan(扫描)thecontents(内容)ofthefilelistboxcontrol
Fori=0ToDir1.ListCount-1
PrintDir1.List(i)
Next

\'scan(扫描)thecontents(内容)ofthefilelistboxcontrol
Fori=0ToDrive1.ListCount-1
PrintFile1.List(i)
Next
depth=-1
WhileDir1.List(pdepth)\"\"
PrintDir1.List(pdepth)
pdepth=pdepth-1
Wend
Print\"thecurrent(当前)folder(文件夹)isnested\"defds123-pdepthdefds123\"foldersdeep\"
回复

使用道具 举报

千问 | 2011-5-22 06:36:43 | 显示全部楼层
为什么我用这段代码扫描出来的文件只显示前六个(不是应该显示全部文件吗)


解释一下行吗?谢谢
回复

使用道具 举报

千问 | 2011-5-22 06:36:43 | 显示全部楼层
你的硬盘分区是不是有6个?你的代码用驱动器个数去读文件
回复

使用道具 举报

您需要登录后才可以回帖 登录 | 立即注册

本版积分规则

主题

0

回帖

4882万

积分

论坛元老

Rank: 8Rank: 8

积分
48824836
热门排行