5 Replies Latest reply on Dec 3, 2012 6:48 AM by David_Entwistle

    How to include an image in a dialog

    David_Entwistle Level 1

      Hello all - I'm creating a dialog window for an Illustrator script, and would like to include a logo image.


      The image file is 'mm_logo.png', and it lies in the same directory as the script itself. Here's the relevant fragment:


      var dlg = new Window('dialog', '',[200,200,600,400]);

      // logo

      dlg.logo = dlg.add("image", {x:25,y:0,width:139,height:67},undefined,'mm_logo.png');


      Sadly the image fails to appear when I run the script (although the dialog itself and items such as panel lines and buttons do appear).


      The documentation suggests I may need to supply the 'current' property of the 'Folder' class. Would someone be kind enough to show me how I do this?