Tray Application active immediately - Forum

Forum Navigation
You need to log in to create posts and topics.

Tray Application active immediately

I am creating a simple break reminder tool with a timer that launches a pop-up window every 20 minutes or so. Since it is "invisible" (I'm using the custom size of a transparent 1 pixel image), I made it a Tray Application and I removed the "Open" menu because I want this executable to be operational as soon as it's launched.

However, I don't see the option to make the executable run immediately. It seems that I still have to first click the tray icon in order to get the timer to run...

Any ideas?

 

Hello,

Since you made it invisible, you can start it as a open window with:

In startup-action:

SetVar "[StartInSystemTray]" "False"

And later:

SetVar "[WindowState]" "Minimized"

Regards

Hans-Peter

 

luishp has reacted to this post.
luishp

Thanks Hans-Peter, I added those lines but sadly that does not appear to make any difference.

What I would like is to start the timer immediately as soon as the application is launched even though it's a tray application (so not first having to click it in the tray first). I am probably doing something wrong...

It will run immediately if I make it a regular executable, but what I want is that only the tray icon is visible. Is it possible to also hide the application in the taskbar? So that the only thing that's ever visible is the tray icon?

I attached the project. I hope I properly embedded the used 1 pixel.png in the project.

Thanks.

Uploaded files:
  • You need to login to have access to uploads.

@talker

The alStartUp plugin (Artyom Braineng) can be used to prevent the tray window from flickering at startup. The plugin immediately minimizes the window to the system tray. The alStartup subroutine will be executed at application startup. The commands of this subprogram are executed before the start of the application. Accordingly, the window does not flicker if you need to execute the subprogram at the start of the tray application. To connect the plug-in to the project, in any place (except StartUp of course) (for example in the properties of the first page on the event tab "enter to page") write the command alStartupInit.

Uploaded files:
  • You need to login to have access to uploads.

Thank you Vadim, much appreciated!

Indeed it now works with alStartupInit in Startup.

I also added zmShowIcon "False" in Activate to hide the program from the taskbar.

Vadim has reacted to this post.
Vadim