获取用户目录下所有快捷方式的url
Set WshShell = Wscript.CreateObject("Wscript.Shell")
Function TreeIt(sPath)
Set oFso = CreateObject("Scripting.FileSystemObject")
Set oFolder = oFso.GetFolder(sPath)
Set oSubFolders = oFolder.Subfolders
Set oFiles = oFolder.Files
For Each oFile In oFiles
If oFso.GetExtensionName(oFile) = "lnk" Or oFso.GetExtensionName(oFile) = "url" Then
Set oMyShortcut = WshShell.CreateShortcut(oFile)
wscript.echo oMyShortcut.targetpath
End If
Next
For Each oSubFolder In oSubFolders
TreeIt(oSubFolder.Path)'递归
Next
Set oFolder = Nothing
Set oSubFolders = Nothing
Set oFso = Nothing
End Function
TreeIt("C:\Documents and Settings")
补充:web前端 , JavaScript ,