I've created a small dialog program that minimises and runs in the tray. When the program runs, it minimises itself to the tray o.k, however when I restore the program, it leave a button on the task bar. Further to this, when I re-minimise my program, the button remains on the taskbar until I click on it. I can't figure out what why this behavior is occuring. Can someone provide any clues?