Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Westi on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

change picture dynamically

Status
Not open for further replies.

presdes

Technical User
Apr 19, 2003
16
US
Hi

Is it possible to change just a picture and keeping all other objects when going from one frame to the next?

I am creating an album, but i want to keep the side graphics but change the pictures. One way would be to copy the keyframe and then change the picture. My only concern with this method is memory usage.

If you know of another way, can you please help me out!

presdes
 
just have an empty clip on stage to hold the pics and dynamically load them in as and when you want.

eg empty clip instance name..... holder

frame 1

loadmovie("first.jpg",holder);


frame 20

loadmovie("second.jpg",holder);


this will automatically unload the first pic and load the second.
 
Hi billwatson

I tried what you said, but when i test the movie it's giving me the error : Error opening URL "file:///C*******

I tried putting in the file path as follows:
loadmovie ("c:\\0001.jpg", holder)
but does not work

any suggestions?

presdes
 
or just put all of the pics into a movie by itself and move through that movie

on (release) {
picsMovie.gotoAndStop(picsMovie._nextFrame);
}
 
if the jpgs are in the same folder as the swf then its just the name of the jpg

loadmovie ("0001.jpg", holder)

if the pics are in a folder then

loadmovie ("images/0001.jpg", holder)

 
what conehead has suggested will work fine but wont address your problem about memory in your post.

all comes down to what you regard as a reasonable file size.
 
Hi guys

i have the pics and the swf in the same folder.
frame 1 : on the movie clip instance there is a button (to advance to the other frames)

frame1: loadmovie("0001.jpg",holder);
stop();

frame 2: loadmovie(0003.jpg",holder);
stop();

but when i test movie i get only the movie clip instance without button nor picture. do you have any idea what i am doing wrong?

what conehead is suggesting i think will take up much more memory than loading the picture

presdes
 
can you post the fla...hard to tell whats wrong from your description
 
Hi Guys

My apologies, I have been away for a few days and i am still struggling with loading just the picture to a clip.
About posting the fla, i can't seem to find a way to do it on this site. Need your help again guys!

presdes
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top