Home Tutorials Forums Articles Blogs Movies Library Employment Press
Old 02-09-2012, 05:33 PM   #1
Registered User
Join Date: Feb 2012
Posts: 2
Default Error #1009

Hello All,

This is my first time posting, and I don't think it will be my last :-/

I am making a simple Ohm's Law Calculator and I am having some troubles. I haven't even progressed to writing the actual math functions on each of the frames because I am stuck :-(
First, here is the frame1 code:


function introClick(event:MouseEvent){
function voltsClick(event:MouseEvent){
function ampsClick(event:MouseEvent){
function ohmsClick(event:MouseEvent){
function wattsClick(event:MouseEvent) {
1.) See attached screenshot : Click image for larger version

Name:	OhmsIntro.jpg
Views:	32
Size:	68.3 KB
ID:	38110
This is the intro frame (frame1)
I want the user to be able to select an output (which will advance to the corresponding frame) and then if they change their mind, they can select a different output and it will go to that frame. Currently, it will only allow me to ADVANCE to a frame and not go back (for example, if the user picks Ohms(frame4) first, it will not let you go to the Amps(frame3) or Volts(frame2). How can I change the code so that it lets me choose the output from each frame?

2.) This error is popping up when I test the file:

TypeError: Error #1009: Cannot access a property or method of a null object reference.
	at OhmsCalc_Scene1_fla::MainTimeline/frame1()[OhmsCalc_Scene1_fla.MainTimeline::frame1:1]

This is probably a really easy answer, so please let me know any solutions or suggestions that you may have.

Minnesnowta is offline   Reply With Quote
Old 02-09-2012, 06:09 PM   #2
Senior Member
Join Date: Apr 2009
Location: Connecticut, USA
Posts: 144

Its hard to say what exactly is causing that error with seeing your .fla. The best way to tackle errors like this, and learn how to get better at finding them, is to analyze and understand what the error message is telling you.

This error is saying, at frame 1, line 1 you are trying to reference an object that AT THAT TIME does not exist. At least it doesn't exist in the place your looking for it in (the main timeline).

So my guess is "volts_btn" is either not present or is named differently than "volts_btn" in your project. Check first to see if this button is there, and if there are any typos.

Make sense?
SLCMemento is offline   Reply With Quote
Old 02-09-2012, 06:27 PM   #3
Registered User
Join Date: Feb 2012
Posts: 2
Default Thanks

Yes, that makes sense... I am now seeing why I shouldn't have used frames to progress from screen to screen in the first place. I am going to follow user Mazoonist's suggestions (on a similar thread) and leave the whole "timeline" alone unless I want animation.

Thanks for the help!
Minnesnowta is offline   Reply With Quote

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 08:48 AM.

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.