Having a bit of a problem creating an instance of an object. Bear in mind that this is timeline based and NOT an external class…
var foo:Object {
var a:String;
var b:String;
}
var new_foo:Object;
function makeFoo():void
{
new_foo = new foo();
}
function doStuff(e:MouseEvent):void
{
makeFoo();
}
Everything runs fine until the 'new_foo = new foo();' bit, at which point I get the #1007 error.
Any ideas?