Can I have a subroutine in a droplet?

Can I have a subroutine in a droplet?

Every time I try to do it my droplet no longer functions.

Here’s how I am writing it

on open (filesToCheck)
…code stuff
validateName(thisFile)
end open

on validateName(thisFile)
…code stuff
end validateName

try replacing the “validateName(thisFile)” within the open command to “my validateName(thisFile)”

-RJ

got the same results

Can you post the complete script?

Jon

Now its working fine, must have been overlooking something the other day which I fixed. Thanks for the help offers.