Hi list i am new to AS2 and in writing classes and there is a question that
i would like to do:
assume i have the following class
Class myClass {
var myName:String;
var myAge:Number:
var myJob:String;
function setName(name) {
name = myName;
}
}
here i declared the myName variable at the beginning
in this class than:
Class myClass {
function setName(myName:String) {
trace("myName");
}
}
and in this other class:
Class myClass {
function setName(name) {
var myName:String;
name = myName;
}
}
now the question is (even if it maight seen silly but i don't get the
concept yet), what is the difference between declaring the variables before
methods (after the class declaration) and declaring them inside the method
itself, or even in the method parameters???
Thanks in advance
--
Omar Fouad - Digital Emotions...
-
Love is always patient and kind. It is never jealous. Love is never boastful
nor conceited It is never rude or selfish. It does not take offense and is
not resentful. Love takes no pleasure in other people's sins...but delights
in the truth. It is always ready to excuse, to trust, to hope... and to
endure... whatever comes.
----------------------------------------
_______________________________________________
[email protected]
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders
Brought to you by Fig Leaf Software
Premier Authorized Adobe Consulting and Training
http://www.figleaf.com
http://training.figleaf.com