4 Replies Latest reply on Jul 25, 2010 5:51 AM by funkysoul

    how to resize at runtime only the height of a flash animation

    slog70

      Hi all,

      I try to explain my problem by example:

       

      I have set a stage to this size: 1200x330 px.

       

      All graphics in this animation area greater than the stage, so I could extend the stage size to 1200 x 450 px.

       

      So, my miz size for the movie is 1200x330 px and max size is 1200x450 px.

       

      Is there a way to show the movie at minimum size or maximum size based on the browser window heigt?

       

      Please note that the movie is put iside a table in my html file.

       

      I would like to obtain something similar to this: http://www.audi.it

       

      If you resize the browser window the flash movie (and only the flash movie) will be shown in different ways.

      If the browser window is higher enough the whole flash movie is shown.

      If the browser window is not higher enough, the top and the bottom of the movie will be cut.

      Of course there is a trick that cuts the movie only to a specified minimum size.

       

      I need something similar.

       

      How can I do this with Flash 8?

       

      TIA for any help.

       

      tony

        • 1. Re: how to resize at runtime only the height of a flash animation
          karthic_vkn Level 1

          Changing stage height is not possible on runtime, but you can do this on different way. For example, your stage height 500x500 it means you can see the object or animation within the stage height. But in runtime you’re trying to animate or expending a text box to exceed the stage height. Then go to publish setting and change the 'Dimension' property value to 'Percent', Now run it on browser, you can able to see the full animation or full text box if browser has enough of space.

          • 2. Re: how to resize at runtime only the height of a flash animation
            slog70 Level 1

            karthic_vkn wrote:

             

            Changing stage height is not possible on runtime, but you can do this on different way. For example, your stage height 500x500 it means you can see the object or animation within the stage height. But in runtime you’re trying to animate or expending a text box to exceed the stage height. Then go to publish setting and change the 'Dimension' property value to 'Percent', Now run it on browser, you can able to see the full animation or full text box if browser has enough of space.

            Hi Karthic, thanks for your reply.

             

            Your solution should work when you have a movie that is alone in the page.

            What about a movie that is inside a table cell?

            I have a 3 rows table and the animation is in the middle cell.

            Here,  is the cell that should resize automatically. Is it right?

             

            Anywhay I would like to change only the height of the movie, without modifying the witdh.

             

            Can't think of a solution to this.

             

            Thanks again, anyway

             

            tony

            • 3. Re: how to resize at runtime only the height of a flash animation
              karthic_vkn Level 1

              you have to changing the cell width and height on runtime, that means just write a javascript function on your html page, that can able to change you cell height and width on run time, when you want to resize your cell, call that java function from your flash,

              • 4. Re: how to resize at runtime only the height of a flash animation
                funkysoul Level 4

                The best solution for your "dilemma" is actually using an intelligent Stage Manager Class..

                Here you can find one: http://evolve.reintroducing.com/2008/03/28/as3/as3-stagemanager/

                 

                With it you can create your layout based on the constraits, as soon the browser is resized everything is moved to the appropriate position.

                I used it for all my projects and I couldn't live without it anymore.