Copy link to clipboard
Copied
This command does not seem to work:
set vertical justification of text frame preferences to bottom align
When I get the properties of the text frame, it does not include vertical justification.
It should work, here are the get replies with 3 text frames in a layer named "Test Layer":
Does a repeat loop work? Something like this:
tell application id "com.adobe.indesign"
tell active document
set tf to every text frame of layer "Test layer"
repeat with x in tf
set vertical justification of text frame preferences of x to bottom align
end repeat
end tell
end tell
Copy link to clipboard
Copied
Hi @defaultzyz99fv4l764 , I think you need to target a text frame, so this would set the vertical justification of a selected text frame:
tell application id "com.adobe.indesign"
set s to selection
if class of item 1 of s is text frame then
set vertical justification of text frame preferences of selection to bottom align
end if
end tell
Copy link to clipboard
Copied
Or, if you are constructing text frames, something like this:
tell application id "com.adobe.indesign"
set measurement unit of script preferences to inches
tell page 1 of active document
set tf to make text frame with properties {geometric bounds:{1, 1, 5, 5}, contents:"Hello", text frame preferences:{vertical justification:bottom align}}
end tell
end tell
Copy link to clipboard
Copied
'sorry I didn't include the complete script. Here it is. Is this a valid script that should work?
tell application "Adobe InDesign 2022"
tell active document
tell every text frame of layer "Test layer"
set vertical justification of text frame preferences to bottom align
end tell
end tell
end tell
Copy link to clipboard
Copied
It should work, here are the get replies with 3 text frames in a layer named "Test Layer":
Copy link to clipboard
Copied
Does a repeat loop work? Something like this:
tell application id "com.adobe.indesign"
tell active document
set tf to every text frame of layer "Test layer"
repeat with x in tf
set vertical justification of text frame preferences of x to bottom align
end repeat
end tell
end tell