取得Disk Volume Information

595599XX

595599XX

2016-02-19 16:50

今天天气好晴朗处处好风光,好天气好开始,图老师又来和大家分享啦。下面给大家推荐取得Disk Volume Information,希望大家看完后也有个好心情,快快行动吧!

  

Private Declare Function GetVolumeInformation Lib "kernel32" _  Alias "GetVolumeInformationA" (ByVal lpRootPathName As String, _  ByVal lpVolumeNameBuffer As String, ByVal nVolumeNameSize As Long, _  lpVolumeSerialNumber As Long, lpMaximumComponentLength As Long, _  lpFileSystemFlags As Long, ByVal lpFileSystemNameBuffer As String, _  ByVal nFileSystemNameSize As Long) As LongConst FILE_VOLUME_IS_COMPRESSED = &H8000Public Sub GetVolInfo(Byval Path as String)Dim aa As LongDim VolName As StringDim fsysName As StringDim path As StringDim VolSeri As Long, compress As LongDim Sysflag As Long, Maxlen As LongVolName = String(255, 0)fsysName = String(255, 0)aa = GetVolumeInformation(path, VolName, 256, VolSeri, Maxlen, _  Sysflag, fsysName, 256)VolName = Left(VolName, InStr(1, VolName, Chr(0)) - 1)fsysName = Left(fsysName, InStr(1, fsysName, Chr(0)) - 1)compress = Sysflag And FILE_VOLUME_IS_COMPRESSEDIf compress = 0 Then  Debug.Print "非Compress之Volume"Else  Debug.Print "Compress之Volume"End IfDebug.Print "Volume Name :", VolNameDebug.Print "Volume Serical# : ", Hex(VolSeri)Debug.Print "Name of the file system (such as FAT, HPFS, or NTFS)", fsysNameDebug.Print "Max Length of File Name ", MaxlenEnd SubPrivate Sub Command1_Click()  Call GetVolInfo("c:")End sub

(本文来源于图老师网站,更多请访问https://m.tulaoshi.com/bianchengyuyan/)
展开更多 50%)
分享

猜你喜欢

取得Disk Volume Information

编程语言 网络编程
取得Disk Volume Information

System Volume Information是什么删除方法

电脑入门
System Volume Information是什么删除方法

s8lol主宰符文怎么配

英雄联盟 网络游戏
s8lol主宰符文怎么配

取得Disk Free Space与Total Space

编程语言 网络编程
取得Disk Free Space与Total Space

取得Disk Driver List与各个Driver的型态

编程语言 网络编程
取得Disk Driver List与各个Driver的型态

lol偷钱流符文搭配推荐

英雄联盟 网络游戏
lol偷钱流符文搭配推荐

Open the sound volume

Linux Linux命令 Linux安装 Linux编程 Linux桌面 Linux软件 Linux内核 Linux管理
Open the sound volume

Display SQL Server Version Information

Web开发
Display SQL Server Version Information

lolAD刺客新符文搭配推荐

英雄联盟
lolAD刺客新符文搭配推荐

BSD是什么系统

BSD是什么系统

设定Mouse 在某个固定范围

设定Mouse 在某个固定范围
下拉加载更多内容 ↓