PDA

View Full Version : Button problem- Flash site button not working from a certain frame.



wren99
July 11th, 2009, 02:13 PM
OK, I absolutely cannot figure this one out. http://www.actionscript.org/forums/images/smilies/confused.gif Can someone help?

I've got a nearly completed Flash site, but one of the buttons isn't working--sometimes.

It's hard to explain, so here's how you can see the problem. Run the .fla below, wait for the animation to stop, and click the "services" star. Two more stars appear: "design and production" and "editorial." If you click on "design and production" first, everything works fine. You can get to editorial and everywhere else. BUT if you click on "editorial" first (after clicking "services" but before clicking "design and production"), the "design and production" button doesn't work from there (the "editorial" label frames in the "inline_frame" movie clip).

I've got several Actions keyframes in the "inline_frame" movie clip--I don't know if that's kosher or not.

Also I'm new to both ActionScript and Flash so go easy with the explanations. I don't know the terminology well.

Thank you so so much to whomever decides to help me out. This site is already overdue, and I need to get it live asap.

Here's the .fla. (http://www.belleetoilestudios.com/index3.fla)

alphaomega
July 12th, 2009, 04:07 PM
Well buddy, I think i might know what the problem is...

Inisde the shooting_stars MC , you have the editorial_btn.

When you click on it, it goes and stops at the "editorial" label inside the inset_frame MC.

But, when it does this, it skips over the action script code written on frame 14 - inside the inset_frame MC.

So, to get it to work,

1)Inisde inset frame MC - go to frame 21.
2)Make a new Keyframe on the actions layer.
3)Write actionscript code - same as the one on frame 14 - with different function names to avoid duplicate function errors.

eg. on frame 14 you have


DP_btn2.addEventListener(MouseEvent.CLICK, handleClick2);
editorial_btn2.addEventListener(MouseEvent.CLICK, handleClick2);

so.. on frame 21,

put it as


DP_btn2.addEventListener(MouseEvent.CLICK, handleClick3);
editorial_btn2.addEventListener(MouseEvent.CLICK, handleClick3);

also change the name of the function on this frame to handleClick3.

Hope this solves your problem.

Let me know if it works.

Regards

Alphaomega

wren99
July 12th, 2009, 04:38 PM
Fantastic. It's fixed.
Thanks so much.

eatpokemons
October 29th, 2009, 01:21 PM
Oh my gawd.
You fixed my problem as well and I am very happy.

Thank you sir.