When developing my WPF application using the RadNotifyIcon, I often catch myself stopping Visual Studio rather than selecting the close application menu option. This results in the tray icon not being removed. When you then restart a debugging session the old icon prevents a new icon from being created as I have a fixed appId. However, as soon as you hover over it, the icon disappears.
Everything is happening per design and in release mode where you have to close the application, everything works fine. This is just some development time frustration.
Is there a way to check on startup if the icon exists (previous remnant) and if so first clear it before creating the new icon? Alternatively, is there a "fool-proof" way to detect ungraceful application close (e.g. stop debugging in VS) to first clear the icon?