Home Tutorials Forums Articles Blogs Movies Library Employment Press
Old 02-19-2010, 02:39 AM   #11
ggalan
Senior Member
 
ggalan's Avatar
 
Join Date: Feb 2006
Location: New York
Posts: 620
Default

Quote:
function loadImage(e:Event):void {
//initializing progress status
MovieClip(root).content_main.progressBar.alpha=0;
MovieClip(root).content_main.progressText.text="";

//initialize image instance ID
var imgID:String="img"+ID;

//Save the loaded bitmap to a local variable
var image:Bitmap = (Bitmap)(e.target.content);

//this will move the thumbnail to stage when image is loaded
MovieClip(root).content_main.preview_pane[imgID].addChild(image);
MovieClip(root).content_main.preview_pane[imgID].x=0;

//remove all listeners
image.removeEventListener(ProgressEvent.PROGRESS, showPreLoader);
image.removeEventListener(Event.COMPLETE, loadImage);
ID++;

//show scroll lines
MovieClip(root).content_main.scroll_box.alpha=1;

//load the next image if there are still more URLs in the array
if (picture_thumbArray.length>0) {
loadPath();
} else {
pageready();
}
}//end of function loadimage
how would you remove the variable image from outside of that function if it is a local variable?
ggalan is offline   Reply With Quote
Old 02-19-2010, 03:27 AM   #12
akagi07
Member
 
Join Date: Nov 2009
Posts: 51
Default

I have changed my coding.
akagi07 is offline   Reply With Quote
Old 02-19-2010, 03:30 AM   #13
ggalan
Senior Member
 
ggalan's Avatar
 
Join Date: Feb 2006
Location: New York
Posts: 620
Default

can you share it?
ggalan is offline   Reply With Quote
Old 02-19-2010, 03:37 AM   #14
akagi07
Member
 
Join Date: Nov 2009
Posts: 51
Default

I do not have the codes with me now as I delivered to my friend.
basically I did was load the image into a container (concept), then load the container to the stage.

When I load the next image, I remove the container, and repeat the first step to load the next image.
akagi07 is offline   Reply With Quote
Old 02-19-2010, 03:42 AM   #15
Renderer10
Registered CS5 User
 
Join Date: Nov 2009
Location: Somewhere in the USA
Posts: 196
Default

I think what ggalan would like to know is how are you going about keeping track of those containers outside the function? I'd be curious to know as well, just to see how someone else approaches things...
__________________
Our brains have just one scale, and we resize our experiences to fit.
Renderer10 is offline   Reply With Quote
Old 02-19-2010, 03:51 AM   #16
ggalan
Senior Member
 
ggalan's Avatar
 
Join Date: Feb 2006
Location: New York
Posts: 620
Default

thank you Renderer10
ggalan is offline   Reply With Quote
Old 02-19-2010, 03:58 AM   #17
akagi07
Member
 
Join Date: Nov 2009
Posts: 51
Default

My apology. I do not have the .fla file with me.
I had 2 functions in my codes. 1 for loading thumbnails and 1 for loading the main picture.

I guess my threat is referring to the thumbnails which like you guys. I'm unable to remove the images. I basically load the new pictures and stack them over the old image.

unable to solve this portion.
akagi07 is offline   Reply With Quote
Old 02-19-2010, 04:10 AM   #18
Renderer10
Registered CS5 User
 
Join Date: Nov 2009
Location: Somewhere in the USA
Posts: 196
Default

Ah, well I could help with that, but it's getting late here and I should really be getting to bed. I'll do my best to help out tomorrow though , it really shouldn't be too hard to work out... Then again, maybe you want your fla first, in which case let me know when you get it and I'll do my best to help then!

-Renderer10
__________________
Our brains have just one scale, and we resize our experiences to fit.
Renderer10 is offline   Reply With Quote
Old 02-22-2010, 09:19 AM   #19
akagi07
Member
 
Join Date: Nov 2009
Posts: 51
Default

sorry for delay as festive season here.

https://www.yousendit.com/transfer.p...UzhlM1EwTVE9PQ

I uploaded a copy of the edited code here.

sorry for the messy structure as I'm not a tidy programmer myself

basically I used the structure to load the images.
akagi07 is offline   Reply With Quote
Reply


Thread Tools
Display Modes Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT. The time now is 07:14 PM.

///
Follow actionscriptorg on Twitter

 


Powered by vBulletin® Version 3.8.5
Copyright ©2000 - 2014, Jelsoft Enterprises Ltd.
Ad Management plugin by RedTyger
Copyright 2000-2013 ActionScript.org. All Rights Reserved.
Your use of this site is subject to our Privacy Policy and Terms of Use.