You are here

SWF best practices

SmartBuilder v3 or v4?

Please note that this is the help site for SmartBuilder version 3.

The SmartBuilder version 4 Documentation and Video Tutorials can be found in the Help menu in the tool, or view the v4 Help site.

In most cases, Flash media will perform as expected in SmartBuilder. If not, verify that the following instructions are followed when creating the .SWF file.

  • Format: Make sure that the export format is Flash Player 8 and ActionScript 2.  ActionScript 3 is not supported at this time.
  • Paths: Use relative paths and local variables for any actions used in the movie such as ../ or _parent.name to reference any scripting element.  Do not refer to the _root.  Try to keep Actionscript code to a minimum and test it after it has been uploaded to SmartBuilder.
  • Object Size: When SmartBuilder loads files, the height and width measurements of the uploaded .swf are based on the first frame of the .SWF file. To ensure that your movie appears in SmartBuilder correctly, create a background shape that is the same size as the Flash authoring page, and is located at coordinates 0,0.  It can have an alpha of 0 so it is invisible, if you wish.
  • Flash Buttons: Are not supported and may cause SmartBuilder objects to fail, or not operate as designed. Note, the SmartBuilder button object includes built-in roll-over and click effects.
  • Animation: If your movie includes an animation, please follow the instructions above regarding object size. Also make sure that the animation starts after the first keyframe to avoid distortion. In order to ensure correct playback, all animations should be made into a movie clip symbol with no stop action in the first frame, instead of putting them into the main timeline. If you want to prevent animation from extending out of the SmartBuilder object border, place a mask over the page area.
  • Authoring Stage: Place the following code on the first frame of the timeline to keep the animation from playing on the Authoring Stage:
  • You cannot use the attachSound() function: The attachSound() function does not work when the swf is being dynamically loaded into another swf. The sound in the library will not play unless it is located in the main swf's library.

    You will need to use one of these two strategies:

    • add the sound to a movieclip's timeline and use the movieclips stop/puase/play methods to control the playback; or
    • you can load sound as mp3 externally.