ScriptSpot

Forum topic · General Scripting

Collect All Images

By JokerMartini · 2011-11-09

Description

What would be the most efficient way of collecting all available and Max acceptable images within a specified directory?


local dir = @"C:\Users\Public\Pictures\Sample Pictures\"
local imageBankArr = getFiles (dir + "*.jpg*")

Comments (2)

JokerMartini · 2011-11-10

Thank you Anubis for the quick response and simple code.

John Martini

maxOps.canImportBitmap

Anubis · 2011-11-09

arrAllFiles = getFiles (GetDir #preview + "/*.*")
arrImgFiles = for file in arrAllFiles where \
maxOps.canImportBitmap file collect file