3 Replies Latest reply on Dec 13, 2012 5:56 PM by CarlosCanto

    Unable to programmatically rename a file using rename()

    aklyman Level 1

      I'm using a Javascript that will export as JPG a series of images from an AI file (that part is working fine), then rename them (that part isn't working). Writing and troubleshooting with Extendscript.


      Trying to eliminate as many possible places to go wrong, I came up with the following:


      myfile = new File; myfile = myfile.openDlg();

      var newName = "NEW.ai";



      When run targeting Illustrator, it does nothing.

      When run targeting ExtendScript, for some reason this blasts the file into oblivion, never to be found again.