Go Back   CodingForums.com > :: Client side development > Flash & ActionScript > Adobe Flex

Before you post, read our: Rules & Posting Guidelines

Reply
 
Thread Tools Rate Thread
Enjoy an ad free experience by logging in. Not a member yet? Register.
Old 04-01-2009, 05:05 PM   PM User | #1
jerry62704
Senior Coder

 
jerry62704's Avatar
 
Join Date: Oct 2007
Location: Springfield, IL
Posts: 1,049
Thanks: 9
Thanked 82 Times in 82 Posts
jerry62704 is on a distinguished road
Question Questions - trace()

I have two questions. One is why I get an error on a trace. The other will be in a different thread. Here is the code:
Quote:
public var tempArray:Array = FSL.getEnglishYesNo();
trace(tempArray);
"FSL" is a class that has all the language properties. There is a "spanishYesNo" to match the "englishYesNo" for example. Here is the error that the trace statement has:
Quote:
1120: Access of undefined property tempArray.
It doesn't make much sense to me that the immediately preceding statement isn't visible - the variable to be traced is defined in the immediately prior statement. The error also occurs if you have literals put into the array.

This is a compile time error found by doing a "project" "clean".
__________________
.
.
...and gladly would he learn and gladly teach

Visit www.LiberalsWin.com for humor and the unique Bush/Obama Approval Polls
jerry62704 is offline   Reply With Quote
Old 10-18-2010, 10:51 AM   PM User | #2
ad7
New to the CF scene

 
Join Date: Oct 2010
Posts: 3
Thanks: 0
Thanked 0 Times in 0 Posts
ad7 is an unknown quantity at this point
Adding the trace statement inside a function will make it work.
ad7 is offline   Reply With Quote
Reply

Bookmarks

Tags
array, error, trace

Jump To Top of Thread


Thread Tools
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 +1. The time now is 10:21 AM.


Advertisement
Log in to turn off these ads.