Skip to content

Instantly share code, notes, and snippets.

@mdauphin
Created October 6, 2016 12:25
Show Gist options
  • Save mdauphin/1a7394e7f7592cd9164bad1ee6d0ed84 to your computer and use it in GitHub Desktop.
Save mdauphin/1a7394e7f7592cd9164bad1ee6d0ed84 to your computer and use it in GitHub Desktop.
Get all videos in argument path and output file size and video length
set objShell = CreateObject("shell.application")
set objFolder = objShell.NameSpace(Wscript.Arguments(0))
For Each fileName in objFolder.Items
set objFolderItem = objFolder.ParseName(fileName)
size = objFolder.GetDetailsOf(objFolderItem, 1)
length = objFolder.GetDetailsOf(objFolderItem, 27)
height = objFolder.GetDetailsOf(objFolderItem, 283)
width = objFolder.GetDetailsOf(objFolderItem, 285)
Wscript.Echo fileName & vbTab & size & vbTab & length & vbTab & height & vbTab & width
Next
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment