/*
GetFirstRemovable是NSIS获取可移动磁盘和U盘盘符的插件
GetFirstRemovable有两个接口GetFirst和GetAll分别用于,获取第一个移动设备盘符,和所有可移动设置盘符.
*/
!AddPluginDir "../Plugins"
OutFile "GetFirstRemovable.exe"
SetCompressor /SOLID lzma
XPStyle on
Page instfiles
Section ""
SetAutoClose true
; Get the first removable drive:
GetFirstRemovable::GetFirst
Pop $R1
; And show it...
MessageBox MB_OK "First removable drive: $R1"
; Get all removable drives:
GetFirstRemovable::GetAll
Pop $R2
; And show them...
MessageBox MB_OK "All removable drives: $R2"
SectionEnd
THE END
暂无评论内容