PDA

Click to See Complete Forum and Search --> : Slow down


Technocrat
Jan 16th, 2002, 12:17 PM
Ok I have this program that checks our email server for new mail and notifies the user that there is new mail when there is some. The problem I have is that there is an icon in the systray that flashes when there is new mail, which work great, until it goes to check for new mail again and the icon pauses for a few seconds. The pause is caused by the program having to excute a bunch of code to check the mail. I have managed to hack out as much as I could but it still pauses. Is there some way to have the systray controls managed by something else? Another program, thread, or something? Any ideas?

CornedBee
Jan 17th, 2002, 08:36 AM
Create a new thread. It let's the icon flash, checks if it's end flag is set and sleeps a while. Then it repeats. If the end flag is set, it ends (wow!).

Technocrat
Jan 17th, 2002, 10:04 AM
Can you give me an example of how to do that with a thread. Just something simple, I can prob figure it out from there

Technocrat
Jan 17th, 2002, 06:29 PM
Thanks for you help! I took your idea and an old sample from Vlatko for threads and I got it to work. Thanks for your help again, it works very well now.