simple count of a type returning nothing

Hello,

OK-practicing my scripting here…and trying to run this simple script to count all the .psd files in my front finder window… I have quite a few, yet it returns 0.
Does anyone know why?
thanks
babs

tell application "Finder"
	count (every document file in the front Finder window whose kind ends with "psd")
end tell

ps-I have also tried .psd too … but nada

Hi,

normally the value of the property kind of a Photoshop file in the Finder is “Adobe Photoshop file”,
you’re probably looking for the name extension


tell application "Finder"
	count (every document file in the front Finder window whose name extension is "psd")
end tell

That worked!!
Thanks Stefen :wink: