PDA

View Full Version : Very Basic Question - Button


FlashN00b1e
04-22-2007, 06:14 PM
Hi,

I really am my handle. I've been working out of the 'Flash 8 in 24 hours' book and I've gotten to the 'loading movies or images' section. I've re-done the example excercise a few times and I can't seem to get a movie (or image) to load when the button's clicked.

http://www.cheapbastid.com/flash/main.swf

I've placed all the files in the same directory and the code is as follows:

In the button
on(click){
_root.theLoader_mcl.loadClip("pic.jpg","theClip_mc");
}

In the document
theLoader_mcl = new MovieClipLoader();

I verified that I named the box correctly as theClip_mc

Can anyone see what I'm goofing?

FlashN00b1e
04-23-2007, 04:00 AM
I did some scanning around the forum and found this code (which works)

on (release) {
_root.theClip_mc.loadMovie("pic.jpg");
}

But being new, I'm still not sure why the method I listed in my first post didn't work.

turtelly
04-23-2007, 06:45 PM
Try what you had originally with on(press) or on(release) instead of on(click)