copying an object... then rotating

So… here I am… in the home stretch…

On page 3 of my indesign file, I have an 8-1/2 x 11 box with a PDF imported in it.

I looked around and haven’t seen any examples to guide me yet.

I will select the graphic prior to running the script, although, it’s the only thing on page 3, so I could have applescript select it.

Then I need to copy the box, including the graphic, to page 2.
Once on page 2, I need to position it using the upper left corner, and resize it based on the upper left corner.
Then I need to rotate it 180 degrees based on the center point.

How about some pointers in the right direction and I’ll try to get the rest…

thanks
david

Hi, David. “Copy”, in this sense, is “duplicate” and “position” is “move to”. Have you downloaded Adobe’s Scripting Guide? It covers basic commands like these and has several examples. If you get stuck, please post your code for evaluation.

http://wwwimages.adobe.com/www.adobe.com/content/dam/Adobe/en/devnet/indesign/sdk/cs6/scripting/InDesign_ScriptingGuide_AS.pdf

that gave me some help… here is where i’m at:

tell myBox
			place file MySheetPDF
			fit myBox given center content
			set myDuplicate to duplicate myBox to page 2 of myDocument
			move myDuplicate to {3, 5.5} given upperleft anchor
		end tell

so I can get myBox duplicated onto page 2, and I can move it… but I am unclear on the syntax of telling it to move it to the new position, according to the upper left anchor point

of course, hopefully this will make it clear to be able to rotate the box given the center anchor point as well.

thanks
david

Move is already relative to an object’s upper and leftmost coordinates; it doesn’t want parameters.

move myDuplicate to {3, 5.5}

that’s all well and good, but what if i didn’t want to use the upper left?

david