8 Replies Latest reply on Sep 4, 2008 6:12 PM by DARIWUDL

    System Tray Icon

    s.lanton
      I am looking for some code that will create a system tray icon when the application is installed. I have a working example of creating such an icon when the app is minimized but not one that is created on install and that stays there even when the app is closed. Anyone?
        • 1. Re: System Tray Icon
          Oliver Goldman Adobe Employee
          The Windows system tray icon feature doesn't work that way; the application must be running in order to have an icon displayed. You can have all of your windows closed, however.

          • 2. Re: System Tray Icon
            abeall Level 3
            Try turning NativeWindow.autoExit to false. You can't force the app to launch after installation, but it is an option given to the user and tehy probably will, then you can use NativeApplication.startAtLogin to have the app automatically launch. Between startAtLogin = true and autoExit = false you'll basically have an always running app.
            • 3. Re: System Tray Icon
              s.lanton Level 1
              Where do I make these settings. I read a lot about setting
              NativeApplication.nativeApplication.startAtLogin=true but no where does it say how to do this?
              • 4. Re: System Tray Icon
                Oliver Goldman Adobe Employee
                This is an API call; you invoke it from your application.

                • 5. Re: System Tray Icon
                  s.lanton Level 1
                  Thanks for that. I have got the application to dock and undock but when the application is docked and the icon shows in the system tray I can't also show the application by clicking on the desktop icon (only the system tray icon) .
                  How can I change that so that both work.
                  • 6. Re: System Tray Icon
                    Oliver Goldman Adobe Employee
                    Listen for InvokeEvent, dispatched by NativeApplication, in order to know when your application has been invoked via its desktop icon.

                    • 7. Re: System Tray Icon
                      abeall Level 3
                      > You can't force the app to launch after installation, but it is an option
                      > given to the user and tehy probably will

                      Okay, am I mistaken, or has this been removed? Or was it never a feature? I just installed an app of mine and after installation I was not given the option to run the application. Is something wrong?
                      • 8. Re: System Tray Icon
                        DARIWUDL
                        Hi s.lanton and hi to all. My Name is Martin and I read about your statement that you’ve got your app to dock and undock. I haven’t had this luck until now.
                        I have managed it to minimize to systray, but unfortunately it displays no icon, so there is no way back to desktop for the app.
                        As far as I understood `till now, in order to display a icon in the systray, 2 arrays are necessary, one for assigning and one for displacing it.
                        I also tried out the example package from the adobe hrc – site ( http://livedocs.adobe.com/air/1/devappsflash/help.html?content=taskbar_1.html), but not only that it is not typed fully correct, it seems not to work (for me). The app is hidden from init on (which should be the case), but also no tray icon is visible, and please believe me, I checked the path to the bitmaps (in my case png`s) one million times. I would be very pleased if somebody could help me out regarding this issue, preferably with a peace of working code :).

                        Many, many thanks in advance and keep on fighting

                        martin