metaphist
May 20th, 2008, 03:46 PM
I get this error on my AS3:
1119: Access of possibly undefined property addTicket through a reference with static type flash.net:LocalConnection.
I'm trying to do this on the AS3:
var LC:LocalConnection = new LocalConnection();
LC.connect('myCon');
LC.addTicket = function() {
trace("whateva");
}
And this on the AS2:
var LC:LocalConnection = new LocalConnection();
traceBtn.addEventListener(MouseEvent.CLICK, traceMe);
function traceMe():void {
LC.send('myCon', 'addTicket');
}
From what I understand, when the AS2 is embedded in the AS3, it should trace when the button on the AS2 is clicked. I've tried between two AS3 movies as well and same error. I've also tried making "LC.addTicket = function ()" into just a regular "function addTicket()" but nothing. Any help?
1119: Access of possibly undefined property addTicket through a reference with static type flash.net:LocalConnection.
I'm trying to do this on the AS3:
var LC:LocalConnection = new LocalConnection();
LC.connect('myCon');
LC.addTicket = function() {
trace("whateva");
}
And this on the AS2:
var LC:LocalConnection = new LocalConnection();
traceBtn.addEventListener(MouseEvent.CLICK, traceMe);
function traceMe():void {
LC.send('myCon', 'addTicket');
}
From what I understand, when the AS2 is embedded in the AS3, it should trace when the button on the AS2 is clicked. I've tried between two AS3 movies as well and same error. I've also tried making "LC.addTicket = function ()" into just a regular "function addTicket()" but nothing. Any help?