5 Replies Latest reply on Aug 23, 2006 10:48 AM by Newsgroup_User

    Movie or stage scale

    MikeLB Level 1
      We are currently doing some research into the possibilities of using flash to run an online questionnaire - the questionnaire will driven by an sql/coldfusion database. The number of questions and responses will vary in length i.e Q1 may only be four lines long and would safely fit within 600px high stage, Q2 may contain fifty lines of check boxes and would need to extend beyond 600px in order to be legible and presentable these would be viewed by scrolling the browser window. So that’s the background - my question is can the stage height be dynamically scaled to accommodate such information/graphics.

      Thanks

      MikeB
        • 1. Re: Movie or stage scale
          Level 7
          MikeB,

          > my question is can the stage height be dynamically
          > scaled to accommodate such information/graphics.

          The Stage cannot be dynamically scaled, but the Stage.onResize event
          alerts you when the Stage *has been* resized by something else, such as the
          user resizing the browser. So the direct answer to your question is "no,"
          but that's misleading. You can, in fact, program movie clips, text fields,
          and so on, to respond to the current size of the movie.

          In addition, the ScrollPane UI Component provides horizontal and
          vertical scrollbars for movie clip content. You could, for example, use
          Stage.onResize to set the width and height of your ScrollPane instance,
          which in turn would provide scrollbars when needed.


          David Stiller
          Adobe Community Expert
          Dev blog, http://www.quip.net/blog/
          "Luck is the residue of good design."


          • 2. Re: Movie or stage scale
            abeall Level 3
            Yes, you can:
            http://2mdc.com/resizableFlash/

            Two things to note:
            1) I'm not sure about browser compatability. I know the old methods were not so good, I think the method being used in the above example is at least compatable with all modern browsers.
            2) Flash has a stage size limit of 2880 x 2880 pixels. That being said, the above example seems to get past that, I'm not sure what is going on, but if I expanded everything found the bottom portion had rendering problems.
            • 3. Re: Movie or stage scale
              MikeLB Level 1
              Thanks for the reply - will take a closer look tomorow (got to pick the kids up now....)

              MkeB
              • 4. Re: Movie or stage scale
                abeall Level 3
                > Yes, you can:
                Oops, sorry David, I posted my response before yours appeared on the forums(classic newsgroup/forum synching issues). Now my response looks condescending since it's so matter of fact after you're lengthy reply, but that was not intended!
                • 5. Re: Movie or stage scale
                  Level 7
                  Hi all,

                  I'm trying to follow a really good tutorial about allowing flash to use a
                  browser's back button within a movie. (It is by Chris Hendershot and can be
                  found here:
                  http://www.actionscripts.org/tutorials/intermediate/Enabling_a_back_button_within_flash/in dex.shtml )

                  Everything is working okay as long as I publish my flash movie in
                  actionscript 1. However, when I publish in AS2 I get errors.

                  I'm no AS genius. Can anyone help me update this code?

                  if(!_level0.$jslisten_init){
                  Stage.$jsvarlistener = new LocalConnection();
                  Stage.$jsvarlistener.setVariables = function(query) {
                  var i, values;
                  var chunk = query.split("&");
                  for (i in chunk) {
                  values = chunk .split("=");
                  _root[values[0]] = values[1];
                  }
                  };
                  Stage.$jsvarlistener.connect(_level0.movieid);
                  _level0.$jslisten_init = true;
                  }

                  The problem is with $jsvarlistener in lines 2, 3 and 11

                  lines 2 and 3 give the error:
                  **Error** Scene=Scene 2, layer=actions, frame=1:Line 2: There is no property
                  with the name '$jsvarlistener'.

                  line 11 gives the error:
                  **Error** Scene=Scene 2, layer=actions, frame=1:Line 11: There is no method
                  with the name '$jsvarlistener'.