Hi, downloaded Flash, 1st post! w00t! need to work out a small project. I
have experience in programming, not specifically OOP, and actionscript seems
to be very OOP. I few questions:
I am loading up some XML per an example:
//ignore whitespace
XML.prototype.ignoreWhite = true;
//create
Hi,
You will need to move external_xml.load call below the onLoad
function because your file will probably be loaded before the handler is
defined (locally).
with trace(myXML) you have defined myXML inside the function -
this means it is not in scope outside the function. Try:
var
Hi,
You will need to move external_xml.load call below the onLoad
function because your file will probably be loaded before the handler is
defined (locally).
with trace(myXML) you have defined myXML inside the function -
this means it is not in scope outside the function. Try:
You have to use a function because the loading is asynchronous. It
doesn't stop program flow while it's loading; it continues with the
program and calls a handler (onLoad) once the load is complete.
I'm not sure this is the proper forum for n00b questions
―
Mike Keesey
, November 09, 2006 4:51 PM
To: Flashcoders mailing list
Subject: Re: [Flashcoders] Noob, basic questions on actionscript,with
methodology suggestions
Hi,
You will need to move external_xml.load call below the onLoad
function because your file will probably be loaded before the handler
Hi,
Apologies, I missed your other question:
You can extend the XML object to include a reference to its parent -
which would contain a function that allowed you to parse it and do
things with your movie, like so:
var external_xml:XML = new XML();
external_xml.parent = this;
Hi,
You will need to move external_xml.load call below the onLoad
function because your file will probably be loaded before the handler is
defined (locally).
with trace(myXML) you have defined myXML inside the function -
this means it is not in scope outside the function. Try:
You have to use a function because the loading is asynchronous. It
doesn't stop program flow while it's loading; it continues with the
program and calls a handler (onLoad) once the load is complete.
Thanks, I understand that part now.
I'm not sure this is the proper forum for n00b
I use to trip over this one, calling xml.load() then immediately trying
to use data from the load, forgetting that I needed to wait for the
onLoad() to tell me that it was done.
Thanks you as well, at least I am not the first to trip up on this, its a
bit wonky coming from other languages,
-
From: [EMAIL PROTECTED]
[mailto:flashcoders-
[EMAIL PROTECTED] On Behalf Of Scott Haneda
Sent: Thursday, November 09, 2006 5:16 PM
To: Flashcoders mailing list; Mike Keesey
Subject: Re: [Flashcoders] Noob, basic questions on actionscript,
with
methodology suggestions
You have to use
I wuz a noob once. I cured it by hanging out with non-noobs.
Thanks, I tend to agree, however, I will move to the flash beginners mail
list, I just hope there are people there who are not as lost as me, as that
probably wont help :-)
--
11 matches
Mail list logo