I've searched through this forum and only found 1 reference to this problem, although it didn't really give me any clues.
What I'm doing is loading a flash movie on a webpage, passing it variables (urls of .jpgs and strings of text to be displayed with the jpgs) and then displaying them in the movie.
I need to be able to get at the width and height of the loaded .jpgs but flash doesn't seem to be cooperating.
Here's my code:
// Here we create a clip in the main movie.
_root.createEmptyMovieClip("mcInst_photoHolder0_mc", 100);
trace( "The name of our newly created movieClip is " + _root.mcInst_photoHolder0_mc._name );
// Now we'll try to load a jpg into our new movieclip
mcInst_photoHolder0_mc.loadMovie(var_photosArray[0].graphic);
// Now we'll see if we can access the width and height of said clip
trace( "The width of the .jpg in mcInst_photoHolder0_mc = " + _root.mcInst_photoHolder0_mc._width );
trace( "The height of the .jpg in mcInst_photoHolder0_mc = " + _root.mcInst_photoHolder0_mc._height );
I'm able to load the .jpg (the url of which is the var_photosArray[0].graphic ) and display it just fine.
When I try to access the _width or _height parameters I get 0.
???
What I'm doing is loading a flash movie on a webpage, passing it variables (urls of .jpgs and strings of text to be displayed with the jpgs) and then displaying them in the movie.
I need to be able to get at the width and height of the loaded .jpgs but flash doesn't seem to be cooperating.
Here's my code:
// Here we create a clip in the main movie.
_root.createEmptyMovieClip("mcInst_photoHolder0_mc", 100);
trace( "The name of our newly created movieClip is " + _root.mcInst_photoHolder0_mc._name );
// Now we'll try to load a jpg into our new movieclip
mcInst_photoHolder0_mc.loadMovie(var_photosArray[0].graphic);
// Now we'll see if we can access the width and height of said clip
trace( "The width of the .jpg in mcInst_photoHolder0_mc = " + _root.mcInst_photoHolder0_mc._width );
trace( "The height of the .jpg in mcInst_photoHolder0_mc = " + _root.mcInst_photoHolder0_mc._height );
I'm able to load the .jpg (the url of which is the var_photosArray[0].graphic ) and display it just fine.
When I try to access the _width or _height parameters I get 0.
???