Error when trying to select two text frames from a layer with script (Error number: 53762)
I am trying to create a script to select two text frames from a layer of a document so that I can copy them to another document. I managed to copy them one at a time, but I need to copy both at once because they are linked by a thread.
When I try to use the code below, I get the following error: "Error number: 53762 / Action is not enabled."
var sourceLayer = sourceDoc.layers.itemByName(layerName);
sourceDoc.activeLayer = sourceLayer;
var actionID = 18455;
app.menuActions.itemByID(actionID).invoke();
Action 18455 tries to select all items in the layer. I tried adding an action to open the layers menu before selecting them, but it made the software crash.
