Hello, I will appreciate any help with this problem; let me describe a little bit what I’m trying to do:
I have 2 SWF, one.swf and two.swf
1 LocalConnection to send 1 variable from one.swf to two.swf
one.swf code:
var param:Number = new Number(5);
var sending_lc:LocalConnection = new LocalConnection();
sending_lc.send("_Connection1", “myMethod”, param);
two.swf code:
this.createTextField(“text1_txt”, 1, 20, 20, 100, 20);
texto1_txt.border = true;
var receiving_lc:LocalConnection = new LocalConnection();
receiving_lc.connect("_Connection1");
receiving_lc.myMethod = function (param:Number){
text1_txt.text = param; //just to test values
temp = param;
};
// I need to do this
Switch (“param value”) {
….
}
This code actually works pretty well sending the “ param ‘ from one.swf to two.swf
Problem:
I need to be able to use “param” value out of the function, because a I need to perform a switch with this value, since the function wich receives de “param” value is an anonymous function I don’t know how to do to get the value from outside the function because a don’t have a reference name to the function so, the normal way to return a value is not going to do the job.
I will appreciate any help, thanks