466 posts
  • Top Monthly Author
  • Trendsetter
  • Weekly Top Seller
  • 6 Years of Membership
+7 more
uiuxaesthetics
says

hey anyone know how to resize a swf on the fly with as3 and also update the embedded swf in the html.

510 posts
  • 5 Years of Membership
  • Affiliate Level 1
  • Author Level 3
  • Beta Tester
+4 more
pxt
says

You can load the SWF into a loader and then put the loader into a movieclip and then resize the movieclip. The new swf can then simply be embedded into a HTML file.

1163 posts
  • Affiliate Level 2
  • Author Level 6
  • Collector Level 3
  • Top Monthly Author
+6 more
FlashTang
says
on the fly

What “on the fly” mean? real time ?

I don’t know if it’s your needed :

Search browsercanvas use google ;)

466 posts
  • Top Monthly Author
  • Trendsetter
  • Weekly Top Seller
  • 6 Years of Membership
+7 more
uiuxaesthetics
says

looks like you use the external inteface and tell javascript to change the width and height of the embedded swf.

178 posts
  • 5 Years of Membership
  • Weekly Top Seller
  • Top Monthly Author
  • Affiliate Level 1
+4 more
Luisreyesdev
says

Put this file in the page

http://s3.envato.com/files/223733/js/div_resize.js

and call the function you want from Flash using ExternalInterface.

Open the js file to see the functions you need.

466 posts
  • Top Monthly Author
  • Trendsetter
  • Weekly Top Seller
  • 6 Years of Membership
+7 more
uiuxaesthetics
says

hell ya dude! I think that is it, I just stumbled on this post the same time you replied. http://danielmclaren.net/2008/04/expanding-resizing-a-flash-swf-using-javascript

466 posts
  • Top Monthly Author
  • Trendsetter
  • Weekly Top Seller
  • 6 Years of Membership
+7 more
uiuxaesthetics
says

Thanks PJ !

178 posts
  • 5 Years of Membership
  • Weekly Top Seller
  • Top Monthly Author
  • Affiliate Level 1
+4 more
Luisreyesdev
says

You would make your swf be

StageAlign = Top-Left

ScaleMode=NoScale

Then have a function call the JS from My previous post. You could do something similar with JQuery to resize the div with animation.

1163 posts
  • Affiliate Level 2
  • Author Level 6
  • Collector Level 3
  • Top Monthly Author
+6 more
FlashTang
says
178 posts
  • 5 Years of Membership
  • Weekly Top Seller
  • Top Monthly Author
  • Affiliate Level 1
+4 more
Luisreyesdev
says
Thanks PJ !

NP!

by
by
by
by
by
by