  | |  | MovieClipLoader Bug | MovieClipLoader Bug 2004-02-13 - By Harper, Chris
Back I know this isn't an FCS question but none of the other forums know how to fix this. I'm using a standard function to import jpegs dynamically. Only problem is that it only works on certain jpegs for some reason. Its like it doesn't like the format or something. Is this a known bug or am I doing something wrong here.
Here is my code:
function loadImage(loadTarget, loadPicture, mc_width, mc_height){ // Create listener object: var loadListener = new Object(); loadListener.onLoadStart = function (loadTarget) { trace("Loading into " + loadTarget + " has started."); } loadListener.onLoadProgress = function(loadTarget, bytesLoaded, bytesTotal) { var percentLoaded = bytesLoaded/bytesTotal * 100; trace("%" + percentLoaded + " into target " + loadTarget); } loadListener.onLoadComplete = function(loadTarget) { trace("Load completed into: " + loadTarget); } loadListener.onLoadInit = function (target_mc){
// you can now do any setup required, for example: loadTarget._width = mc_width; loadTarget._height = mc_height; } loader = new MovieClipLoader(); loader.addListener(loadListener); loader.loadClip(loadPicture, loadTarget); }
-- ---- ---- ---- ---- ---- ---- ---- ---- ---- ---- ---- ---- ------ Supported by Fig Leaf Software -- ---- ---- ---- ---- ---- ---- ---- ---- ---- ---- ---- ---- ------ Lower Prices for Certified Training! Check out new lower prices for Certified Macromedia Training from Fig Leaf Software. Expand your skill set with courses in ColdFusion, Flash, Rich Internet Applications and .NET in the new year. Fig Leaf Software provides the highest caliber instruction at our training centers in Washington D.C., Atlanta, Chicago, Baltimore, Northern Virginia, or on-site at your location.
Get the details at http://training.figleaf.com/ -- ---- ---- ---- ---- ---- ---- ---- ---- ---- ---- ---- ---- ------ To unsubscribe, e-mail: flashcomm-unsubscribe@(protected) For additional commands, e-mail: flashcomm-help@(protected)
Earn $52 per hosting referral at Lunarpages.
|
|
 |