I want to create a gadget. when opening windows they appear on the shell tray as:

how can I prevent a window from showing on that tray. I already know how to send a window to the back to make it appear as a gadget. I found that example in here. It will be nice if that menu does not show up meanwhile the window is active and open.
Use the Window property
ShowInTaskbarto restrict or allow your Window to appear in the taskbar.