Hi all. I have one strange problem.
1. I have a script which delete actions and upload new versions of deleted
function deleteActionSet(actionSetName) {
try {
var iddelete = charIDToTypeID("Dlt ");
var desc = new ActionDescriptor();
var ref = new ActionReference();
ref.putName(charIDToTypeID("ASet"), actionSetName);
desc.putReference(charIDToTypeID("null"), ref);
executeAction(iddelete, desc, DialogModes.NO);
} catch (e) {
alert(e.message)
}
}
deleteActionSet("Set1");
deleteActionSet("Set2");
app.load(new File("C:/Program Files/Adobe/My Tools/Actions/Set1Updated.atn"));
app.load(new File("C:/Program Files/Adobe/My Tools/Actions/Set2Updated.atn"));
alert("UPDATED!");
2. I have an action which launch this script
So i have a problem with launching script using actions. After launching action my old actions was deleted and "UPDATE!" message was showed and thats all. I don't see new, updated, actions. But if i starting script by File-Scripts-Browse it works correctly. Old actions deleting and new adding and i don't know why and how can i fix it.
Sorry for my Eng.