2 Replies Latest reply on Mar 4, 2008 3:34 AM by Loic.Aigon

    [JS] > Is it only possible to switch and operate between two apps on a loop ?

    Loic.Aigon Adobe Community Professional
      b I would like to know if there is possible to switch and operate between Indesign & Illustrator.

      In my mind, I would like to write a code that converts ai file to indd. Converting means recreate the ai doc(size, page elements, links) to indd with indd native elements.

      i (What for ? Well Indy allows much more composition options like in wrapping panel for example).

      I looked for analyzing the ai file as raw text but it seems too ambitious for me.
      So I thought about just opening the ai file and then identifying page elements one by one and finally recreate them into Indesign in a loop.
      However, I don't find any leads on switching between apps. The better I get is just launching a ai file.

      I don't have any real needs for that so it does not worth to spend a lot of time on this topic. I am just curious to know if it's possible or not.

      Thanks for experiences.
      Loic
        • 1. Re: [JS] > Is it only possible to switch and operate between two apps on a loop ?
          Kasyan Servetsky Level 5
          Hi Loic,

          I think it’s quite possible. You can do this using BridgeTalk message object (don’t confuse it with Bridge application). You can get detailed information about it in the “Interapplication Communication with Scripts” chapter in JavaScript_Tools_Guide_CS3.pdf.
          In illustrator you can unlock all layers and objects, remember parameters of the document you need: page height, page width and so on, then select all objects, copy. The in InDesign create a document using the same height, width and so on, then paste, save and close document. But it will work, if illustrator documents consist of quite simple objects, otherwise the objects will be pasted as one PDF object into InDesign.
          I made a few scripts using inter application communication e.g. InDesign and Photoshop, but I’ve never made scripts for Illustrator, because don’t use it often. Debugging of such scripts in JS is a little difficult – in AS and VB it’s done much easier. If you are interested, you can read a good book with a lot of examples – Adobe illustrator scripting by Ethan Wilde – but it doesn’t cover JS – only AS and VB.

          Kasyan
          • 2. Re: [JS] > Is it only possible to switch and operate between two apps on a loop ?
            Loic.Aigon Adobe Community Professional
            Hi Kasyan,
            Thanks a lot for very detailed response. At least, now I know it's worth to spend time on this if it's possible. I am following your advice and read carefully the JavaScript_Tools_Guide_CS3.pdf.
            Thanks for taking the time to reply.
            Bye Loic