Creative Communities of the World Forums

The peer to peer support community for media production professionals.

Activity › Forums › Adobe After Effects › Extendscript .getFiles function is undefined

  • Extendscript .getFiles function is undefined

    Posted by Wayne Grech on December 23, 2019 at 4:22 pm

    Scripting newbie here, I’m trying to figure out a way of creating an array and populating it with all the files within a user specified folder.

    This is what I got:

    var myFolder = Folder.selectDialog (“Select a folder”);
    var allfiles = myFolder.getFiles();

    however it just gives me an error telling me that myFolder.getFiles is undefined.
    I’ve been looking around online and everyone seems to be using this function for the same thing i’m trying to achieve.

    Would appreciate any help thank you.

    Wayne Grech replied 6 years, 9 months ago 2 Members · 2 Replies
  • 2 Replies
  • Dan Ebberts

    December 23, 2019 at 9:01 pm

    That’s the right function. Your code works fine for me–I’m not sure why it doesn’t work for you. Maybe a permissions thing? Do you have the preference set that allows scripting to access the network?

    Dan

  • Wayne Grech

    December 30, 2019 at 8:50 am

    Hey Dan, thanks for the suggestion but it seems that those permissions are enabled and I still get the same error for some reason.. any other ideas?

We use anonymous cookies to give you the best experience we can.
Our Privacy policy | GDPR Policy