2 Replies Latest reply on Jul 3, 2014 9:30 AM by Harbs.

    Save as FXG option not working from script.  Am I doing this right?

    omuppi1

      I see that the Illustrator Scripting reference document for CC 2014 [1] has references to FXG, FXGSaveOptions, etc.  I thought I would give it a try to see if I can save a document to FXG.  Here is what I am trying:

       

      var myDocument = app.documents[0];
      var myTextFrame = myDocument.textFrames.add();
      myTextFrame.position = [200,200];
      myTextFrame.contents = "Hello World!"
      
      var newFile = new File("c:/temp/fxgfile");
      var fxgSaveOptions = new FXGSaveOptions();
      myDocument.save(newFile,fxgSaveOptions);
      
      

       

      This causes the file to get saved as fxgfile.ai and not fxgfile.fxg that I was looking for.

       

      Any ideas?

       

      Thanks,

      Om

       

      [1] http://wwwimages.adobe.com/content/dam/Adobe/en/devnet/illustrator/sdk/CC2014/Illustrator% 20Scripting%20Reference%20-%20…