ErrStrs = {}; ErrStrs.USER_CANCELLED=localize("$$$/ScriptingSupport/Error/UserCancelled=User cancelled the operation"); try {var idsetd = charIDToTypeID( 'setd' );     var desc1016 = new ActionDescriptor();     var idnull = charIDToTypeID( 'null' );         var ref831 = new ActionReference();         var idPrpr = charIDToTypeID( 'Prpr' );         var idblendOptions = stringIDToTypeID( 'blendOptions' );         ref831.putProperty( idPrpr, idblendOptions );         var idLyrsp = charIDToTypeID( 'Lyr ' );         var idOrdn = charIDToTypeID( 'Ordn' );         var idTrgt = charIDToTypeID( 'Trgt' );         ref831.putEnumerated( idLyrsp, idOrdn, idTrgt );     desc1016.putReference( idnull, ref831 );     var idTspspsp = charIDToTypeID( 'T   ' );         var desc1017 = new ActionDescriptor();         var idblendOptions = stringIDToTypeID( 'blendOptions' );         var idblendOptions = stringIDToTypeID( 'blendOptions' );         desc1017.putClass( idblendOptions, idblendOptions );     var idblendOptions = stringIDToTypeID( 'blendOptions' );     desc1016.putObject( idTspspsp, idblendOptions, desc1017 ); executeAction( idsetd, desc1016, DialogModes.ALL ); } catch(e){if (e.toString().indexOf(ErrStrs.USER_CANCELLED)!=-1) {;} else{alert(localize("$$$/ScriptingSupport/Error/CommandNotAvailable=The command is currently not available"));}}