1 Reply Latest reply: May 28, 2014 11:06 AM by Gonterman1201 RSS

    Delete nodes in separate folder from viewed thumbnails

    Gonterman1201 Community Member

      I want to delete part of this tree. I have a folder that has multiple folders inside it. One specific folder needs to be emptied after the operator clicks a button. Do I need to create thumbnails for all of these files to delete them. Or can I just use their file strings and use app.deleteCollection?

        • 1. Re: Delete nodes in separate folder from viewed thumbnails
          Gonterman1201 Community Member

          Ok I have a solution. I used the command line to delete the files for me. You just have to give it the right directory and poof gone. Here is how it goes.

           

          poopPanel.addBtn.onClick = function(){

                      myPath=app.document.presentationPath;

                      deleteF="rm -r "+myPath.slice(0,39)+"imaging/*";

                      app.system(deleteF);

          using the directory you are on I delete of some of the directory and add the folder I want to create the new directory. Then give that to command line.