nathanlukewong
asked on
vbscript get file extension
Hi guys was wondering if anyone knew why i cant get this code to run?
Cheers
Nathan
Cheers
Nathan
Set objFSO = CreateObject("Scripting.FileSystemObject")
objStartFolder = "D:\"
Set objFolder = objFSO.GetFolder(objStartFolder)
Set objExtension = objFSO.GetExtensionName("D:/")
Set colFiles = objFolder.Files
For Each objFile in colFiles
If objExtension = "jpeg" then
Wscript.Echo objFile.Name
End if
Next
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.