I'm not familiar with Basil.js, but if you look at the InDesign reference for a PageItem
, you'll notice that there is a function called insertLabel
that you can use to insert a label into a PageItem
. You might also want to look at the label
property.
How can I dynamically attach a scripting label to a newly created item in basil.js?
-
14-04-2022 - |
Question
Is there a way to add scripting labels to PageItems that are created in code, i.e. without using the Scripting Label panel?
My code looks like this:
var tf = b.text("Hello World", 200, 200, 300, 300);
Solution 2
OTHER TIPS
var tf = b.text("Hello World", 200, 200, 300, 300);
tf.label = "textframe_hello_world";
b.println(tf.label)
as josh said, the property "label" should do the trick.
Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow