MJ> OK, I see, so then curious why this script returns compiler errors:
MJ> 
MJ> function createData():Void {
MJ>     this._data = new Object();
MJ>     this._data["a"] = new Object();
MJ>     this._data["a"] = {"t1":0, "t2":0};
MJ> }

Because when using the object initializer operator, you cannot use
strings as identifiers (similarly to variable declaration).
In the above script the this._data["a"] = new Object(); line is simply
not necessary, and the right syntax of the last one is:

this._data["a"] = {t1:0, t2:0};

or even better:

this._data.a = {t1:0, t2:0};

  Attila

_______________________________________________
[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

Reply via email to