Can't add children to the stage via a class
hi there,
i trying addchild(displayobject) via class, , nothing appears when add stage. please!
class
package com.ryancanulla.utils
{
import flash.display.sprite;
import mx.controls.textarea;
public class archivedata extends sprite {
private var test:textarea = new textarea;
public function archivedata():void {
//var testtext.text = "this test";
test.text = "this test";
addchild(test);
}
}
}
calling class
private var archivedata:archivedata;
archivedata = new archivedata();
make class document class. or pass reference displayobject.
More discussions in ActionScript 3
adobe
Comments
Post a Comment