ErrStrs = {}; ErrStrs.USER_CANCELLED=localize("$$$/ScriptingSupport/Error/UserCancelled=User cancelled the operation"); try {var idDplc = charIDToTypeID( 'Dplc' );     var desc843 = new ActionDescriptor();     var idnull = charIDToTypeID( 'null' );         var ref713 = new ActionReference();         var idDcmn = charIDToTypeID( 'Dcmn' );         var idOrdn = charIDToTypeID( 'Ordn' );         var idFrst = charIDToTypeID( 'Frst' );         ref713.putEnumerated( idDcmn, idOrdn, idFrst );     desc843.putReference( idnull, ref713 ); executeAction( idDplc, desc843, DialogModes.ALL ); } catch(e){if (e.toString().indexOf(ErrStrs.USER_CANCELLED)!=-1) {;} else{alert(localize("$$$/ScriptingSupport/Error/CommandNotAvailable=The command is currently not available"));}}