Use the "script label" panel.
Thank you very much !
1 person found this helpful
It sounds like the OP must be using CS4, but for the benefit of anyone coming across this thread later: use the Script Label panel in CS4 and below, but the Layers panel in CS5 and above.
I'm confused by this. I'm using CS6 and if I set the name using the "script label" panel, getting the item by name does not work. How could you use the layers panel to get a single text frame? More than one text frame can be placed on a layer.
Are you saying that if the layer is name "foo", that the following statement will return the first text frame in that layer?
oMyBloc = currentPage.textFrames.item("foo");
I figured this out. Each layer in the layers panel can be expanded to show each of the items in the layer. You can change the default name of each item. Then from scripting you can reference items by those names.