2 Replies Latest reply on Jun 26, 2009 9:50 AM by Joe Bobzien

    Align page items (AS) (CS3)

    Joe Bobzien

      Scripting Gurus,

       

      Is there some simple AS syntax to align selected page items on a page?

       

      Dictionary seems to imply that, saying:

      align distribute items page item : The page items to align or distribute.

      align option left edges/top edges/right edges/bottom edges/horizontal centers/vertical centers : The type of alignment to apply.

       

      I attempted this:

      tell page items in selection

      set vertical alignment to top edges

      end tell

       

      Thanks!

      Joe

        • 1. Re: Align page items (AS) (CS3)
          Randomsen Level 1

          Its kinda of crazy but here ya go, I wish the AppleScript Dictionary listed  examples ...esp. when the syntax is wacky.

           

          select a bunch of images, or have the object references in a list(I just use selection to make it easier):

           

          tell application "Adobe InDesign CS3"

              tell active document
                  set myimages to selection

                  align align distribute items myimages align option left edges
              
              end tell

           

          The text in the red is where you put those paramaters listed in the dictionary.

           

          ~Mike

          • 2. Re: Align page items (AS) (CS3)
            Joe Bobzien Level 1

            Mike,

             

            God Bless You.

             

            Yes, where is the WACKY SYNTAX resource !  I searched the net for two hours yesterday looking for these nine words.

             

            I knew it would be something like "align align distribute distribute items myItems wackywacky preferences option top edges" 

             

            Again thank you and all other contributors to this forum !!!!

             

            Joe