1 Reply Latest reply on Apr 8, 2009 10:03 PM by anirudhs

    LocalConnection stay connected but it shoudn't

    ssoucy
      Hello,
      We are using LocalConnection to see if another instance of an application is already running. So, At the application creationComplete, we try to connect to a static channel ID. If the connection fail, we know that there's another application connected to this channel. This works fine. The problem is if you have any other flash running in your computer and the process who made the LocalConnection.connect() is close abruptly (kill, crash). We would never be able to connect to the channel ID until all other flash player are closed. To reproduce this issue it's simple. Just create a simple AIR application with nothing into it. Run It and don't close it. Create a flex application with this code in the creation complete handler:

      lc = new LocalConnection()
      try
      {
      lc.allowDomain("*");
      lc.connect("_TestCommChannelId");
      }catch(error:Error)
      {
      Alert.show("Instance already exists");
      }

      if you run the flex application, then you kill your web browser, next time you try to run the flex application will always throw the error until you close the AIR application.

      Anyone can help me with this issue, have any idea to solve this or know if this problem is known by Adobe?