The following code works on each browser, (ie: when opening a second tab on chrome it wont run the SWF, but if I open the swf on IE or Safari it runs and it shouldn't!).
I need to allow only 1 SWF at a time no matter what browser the SWF is running on. is it possible? Thans guys!
public function LCTest():void
{
lc = new LocalConnection();
lc.addEventListener(StatusEvent.STATUS, localStatusHandler);
lc.client = this;
lc.allowDomain("*");
try
{
lc.connect("_myLCLock"); // underscore for global scope
trace("SWF NOT RUNNING, START MY APP");
}
catch (e:ArgumentError)
{
trace("SWF OPEN IN ANOTHER WINDOW/TAB/BROWSER, DON'T RUN THE APP");
}
}