Hello, I have an application that sits in the windows system tray. This application flashes at certain intervals. The way I do this is by using a timer, and change the icon every second for a shor interval. This gives the effect of a flashing icon. All of this works good without issues. Here is where the problem starts. I noticed that if the computer goes into standby mode or hibernation and then starts again, if an icon hadn't previously been shown (flashing hadn't occured yet) the icon that hadn't been shown before standby-mode shows as black. The shape of the icon is correct but is black. The current icon that the application was displaying in the system tray before the stand-by mode shows correct color and all. Anybody have any idea what the issue could be?
Keep in mind that the icons to be displayed are stored in image objects that are on the main form of the application. I tried putting the icons into an imagelist and still had the same issue.
This is how I flash the icon in the system tray using an ImageList object. The same occurs using an Image object.
Thanks for any insight in what may be causing this.Code:nid.hIcon = Me.imgIcon.ListImages(0).Picture Shell_NotifyIcon NIM_MODIFY, nid nid.hIcon = Me.imgIcon.ListImages(1).Picture Shell_NotifyIcon NIM_MODIFY, nid




Reply With Quote