0 Replies Latest reply: Nov 30, 2010 3:51 AM by chapmanga RSS

    Write to dialog box

    chapmanga Community Member

      I have a short script I use to determine the dimensions of artwork and artboards in a given file, at present it just writes out to the JavaScript console in ESTK.

       

      var docRef = app.activeDocument;
      var artboard = docRef.artboards[0];
      if(version > 13)
          {
          if(overflowDoc.artboards.length > 1)
              {
              var dlg = prompt("Object should be inside which artboard?", "1", "Artboard number?");
              var artboard = (dlg != null) ? overflowDoc.artboards[parseInt[dlg]-1] : artboard;
              }
          }
       
      with (docRef) {
           $.writeln(geometricBounds);
           $.writeln(artboard.artboardRect);
      }
      

       

      Rather than write to the console is it possible to return these values to a dialog box that has called the function so that standard users can see the results?

      Any help appreciated.