2 Replies Latest reply on Mar 9, 2016 5:39 AM by Mattmcquiff

    add metadata via photoshop

    Mattmcquiff Level 1

      I have this script to currently use while about to save an image however I would like to remove the save as and just simply make a script that when run adds the metadata.


      function saveAS() {
      if(!documents.length) return;
      activeDocument.info.captionWriter = "Editted_by_Test";
      if(activeDocument.layers.length > 1){
      var desc2 = new ActionDescriptor();
      var desc3 = new ActionDescriptor();
      desc3.putBoolean( stringIDToTypeID('maximizeCompatibility'), true );
      desc2.putObject( charIDToTypeID('As  '), charIDToTypeID('Pht3'), desc3 );
      try{executeAction( charIDToTypeID('save'), desc2, DialogModes.ALL );}catch(e){}
      try{executeAction( charIDToTypeID('save'), undefined, DialogModes.ALL );}catch(e){}
      #target photoshop



      Many Thanks