zille 0 Posted November 14, 2013 Report Share Posted November 14, 2013 (edited) I have made a small quiz application in flash. Beginner. I have added this code for "Select Country" button : scountry.addEventListener(MouseEvent.CLICK, goscountry);function goscountry(event:MouseEvent):void{ gotoAndPlay(1, "Map");} I get error So I tried this: ArgumentError: Error #2108: Scene Map was not found. at flash.display::MovieClip/gotoAndPlay() at Assignment1_Menu_fla::MainTimeline/fl_ClickToGoToScene_9() scountry.addEventListener(MouseEvent.CLICK, goscountry);function goscountry(event:MouseEvent):void{ gotoAndPlay(1, "Map");} I get error again: ArgumentError: Error #2108: Scene Map was not found.at flash.display::MovieClip/gotoAndPlay()at Assignment1_Menu_fla::Nav1_4/goscountry() Can anyone help me linking the Map Scene with button "Select Country" button in Main Scene. The project file is attached: Natok (27MB) Edited November 14, 2013 by zille Quote Link to post Share on other sites
justsomeguy 1,135 Posted November 15, 2013 Report Share Posted November 15, 2013 Those 2 pieces of code are the same. I haven't downloaded the 27MB project file, but you might not be targeting the correct movie clip with gotoAndPlay. Normally you would specify a movie clip with that, like _parent.gotoAndPlay or _root.gotoAndPlay, or the instance name of an existing movie clip. Quote Link to post Share on other sites
Ingolme 1,022 Posted November 15, 2013 Report Share Posted November 15, 2013 Is the scene called "Map" or is it something else, like "map" or "MAP"? Quote Link to post Share on other sites
zille 0 Posted November 24, 2013 Author Report Share Posted November 24, 2013 Actually my code was correct. I was click on "Test Scene" and button not working but when I clicked on "Test Movie" it was working fine. Thank you Quote Link to post Share on other sites
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.