Support Flash Element ActionScript 3.0

Ask a Question related to Macromedia Exchange Dreamweaver Extensions, Design and Development.

  1. #1

    Default Support Flash Element ActionScript 3.0

    I have made flash component for the test.
    In Flash CS3 all works perfectly. I create extension for Dreamweaver CS3. For
    an insert of a component on page I use a code
    "dw.getDocumentDOM().insertFlashElement('MyCompone nt.swc')", in file MXI. At
    attempt to insert component Dreamweaver gives out the message " The MyComponent
    Flash Element could not be found ". With components ActionScript 2.0, similar
    problems were not. What is the problem? Whether supports Dreamwever such
    components?

    // MyComponent.as

    package {
    import flash.display.Sprite;
    import flash.text.TextField;
    public class MyComponent extends Sprite {
    private var _tf:TextField;
    private var _width:Number = 0;
    private var _height:Number = 0;
    private var _background:Sprite;
    public function MyComponent() {
    init();
    createChildren();
    draw();
    }
    private function init():void {
    _width = width;
    _height = height;
    scaleX = 1;
    scaleY = 1;
    removeChildAt(0);
    }
    private function createChildren():void {
    _background = new Sprite();
    _tf = new TextField();
    _tf.autoSize = "left";
    addChild(_background);
    addChild(_tf);
    }
    protected function draw():void {
    _background.graphics.clear();
    _background.graphics.beginFill(0xFF0000, 1);
    _background.graphics.drawRoundRect(0, 0, _width, _height, 10, 10);
    _background.graphics.endFill();
    _tf.text = "w: " + _width + ", h: " + _height;
    _tf.x = Math.floor((_width - _tf.width)/2);
    _tf.y = Math.floor((_height - _tf.height)/2);
    }
    public function setSize(w:Number, h:Number):void {
    _width = w;
    _height = h;
    draw();
    }
    }
    }

    NullDesigner Guest

  2. Similar Questions and Discussions

    1. Spry Menu Bar & Flash Element
      The Spry menu bar widget works fine, except that on two pages where I have Flash elements at the top of the page (just under the bar) the Menu bar...
    2. pop-up menu showing up behind flash element
      I have a website that i am working on (www.arfsepa.com/test) and the navigation on the left side of the page has a pop-up menu. The problem is that...
    3. flash element
      Hi, I purhased a flash element for nav bar from f-source.com and it works great in netscape, but not in ie. here is the code <object...
    4. Problem with Flash element - mirror reflection!
      Could anyone help? We are getting the sporadic error on our web page running flash-based element - as a result, our nice animated text+images element...
    5. [HTML::Element] how to read element by element
      Hello I read the doc about HTML::Element, but I don't find how to read the tree create by parse() element by element. The doc says the tree looks...
  3. #2

    Default Re: Support Flash Element ActionScript 3.0

    Just the same problem. AS 3.0 SWC files have different structure (there are no
    *.asi files inside it and the catalog.xml is different). Unzip your SWC file
    and change the library.swf file name to the name of your component
    (FooterNav.swf for example). After that just zip it again and create new MXP.
    In this case you'll get rid of the "could not be found" error. But this doesn't
    solve the problem with element parameters - the "Flash Element" panel is just
    empty.

    It looks like Dreamweaver CS3 just doesn't have normal support for AS 3.0
    Flash Components yet.

    constsi Guest

  4. #3

    Default Re: Support Flash Element ActionScript 3.0

    constsi wrote:
    > Just the same problem. AS 3.0 SWC files have different structure (there are no
    > *.asi files inside it and the catalog.xml is different). Unzip your SWC file
    > and change the library.swf file name to the name of your component
    > (FooterNav.swf for example). After that just zip it again and create new MXP.
    > In this case you'll get rid of the "could not be found" error. But this doesn't
    > solve the problem with element parameters - the "Flash Element" panel is just
    > empty.
    >
    > It looks like Dreamweaver CS3 just doesn't have normal support for AS 3.0
    > Flash Components yet.
    >
    Given that Adobe is removing Flash Elements from the next version of Dreamweaver, I'd be quite surprised if they did any more work to include AS3 support inside of Dreamweaver CS3. Read the features to be removed:
    [url]http://kb.adobe.com/selfservice/viewContent.do?externalId=kb402489&sliceId=1[/url]


    --
    Danilo Celic
    | Extending Knowledge Daily : [url]http://CommunityMX.com/[/url]
    | Adobe Community Expert
    danilocelic AdobeCommunityExpert Guest

  5. #4

    Default Re: Support Flash Element ActionScript 3.0

    [q]Given that Adobe is removing Flash Elements from the next version of
    Dreamweaver, I'd be quite surprised if they did any more work to include AS3
    support inside of Dreamweaver CS3. Read the features to be removed: [/q]

    Such information must be included into the official "Extending Dreamweaver
    CS3" document. Its current version describes the Flash Elements API but there
    are no any notes about the lack of AS3.0 SWCs support. We spent several hours
    trying to follow the official document instructions.

    constsi Guest

  6. #5

    Default Re: Support Flash Element ActionScript 3.0

    constsi wrote:
    > [q]Given that Adobe is removing Flash Elements from the next version of
    > Dreamweaver, I'd be quite surprised if they did any more work to include AS3
    > support inside of Dreamweaver CS3. Read the features to be removed: [/q]
    >
    > Such information must be included into the official "Extending Dreamweaver
    > CS3" document. Its current version describes the Flash Elements API but there
    > are no any notes about the lack of AS3.0 SWCs support. We spent several hours
    > trying to follow the official document instructions.
    >
    Livedocs allow you to add comments on specific pages, if what you've found is true, that Flash CS3 SWCs are not compatible with Dreamweaver CS3 I'd suggest you added you findings on the appropriate pages:
    [url]http://livedocs.adobe.com/en_US/Dreamweaver/9.0_API/index.html[/url]


    --
    Danilo Celic
    | Extending Knowledge Daily : [url]http://CommunityMX.com/[/url]
    | Adobe Community Expert
    danilocelic AdobeCommunityExpert Guest

Posting Permissions

  • You may not post new threads
  • You may post replies
  • You may not post attachments
  • You may not edit your posts

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139