0 Replies Latest reply on May 27, 2008 9:25 AM by and_p_

    JSAPI addNewText inside button

    and_p_
      Hi,
      I would like to addNewText inside my button, on the second layer in the first frame.
      (my .jsfl file):
      ///////////////////////////////////////
      function create(){
      try
      {
      fl.getDocumentDOM().library.addNewItem("button", "Buttons/btn");
      var closeBtn = fl.getDocumentDOM().library.findItemIndex("Buttons/btn");
      var closeBtn_timeline = fl.getDocumentDOM().library.items[closeBtn].timeline;
      closeBtn_timeline.addNewLayer("btn text","normal",false);
      }
      catch(e){}
      }
      create();
      ///////////////////////////////////////

      Any ideas?