I am VERY new to actionscripting and have got myself into a bit of a muddle. I am trying to import a jpeg image into an empty movie clip and then resize the image. I can scale it, and position it but I can’t resize it.
Somebody suggested creating a movieclip in Flash first and giving it an instance name. Then use loadMovie to place the jpeg into that movieclip. This did work and allowed me to resize it but only the movieclip would be resized which in turn resized the image proportionally. I still couldn’t specify exact dimensions of the image - only the movieclip. I hope this makes sense… I think I’ve lost myself!!
Thanks for the reply. However I’m still having problems. There seems to be a problem with the IF statement. It never returns true. Should there be some sort of loop to test how much of the movieclip has loaded?
I always have trouble testing getBytesTotal against getBytesLoaded with jpeg loads as well, so in Scotty’s code, I would just leave out the t==l. Since the width and height aren’t set till it is loaded anyway, their checks should be sufficient. Try
if (t == l && t != 0 && cab._width>0 && cab._height>0) {