Application.SetSysTrayIcon

boolean Application.SetSysTrayIcon (

string IconPath,

number IconIndex = 0 )

Description

Sets the application's system tray icon using an icon file or executable, or reverts back to the original application icon.

Note: This action requires that you specify that the application contains a system tray icon. This setting can be configured on the Appearance tab of Project > Settings in the Taskbar area.

Parameters

IconPath

(string) The full path to a file containing the icon you want to use. The most common types are icon files (.ico) and executables (.exe). If no icon path is specified, the system tray icon will revert back to its original application icon.

IconIndex

(number) The zero-based index describing which icon to use in the executable file. For example, an icon index of 2 means it will use the third icon in the file. For .ico files, leave this value 0.

Returns

(boolean) True if the action was successful, and false if it failed. You can use Application.GetLastError to determine whether this action failed, and why.

ResultVariable

When adding an action with the script editor, you can use this field to specify a variable that the return value will be stored in.

See also: Related Actions