To remove a ghost tray icon, maybe a better way exists, but I know only the "mouse move" way. Find it as accessible object and mouse-move.
Macro Macro3030
or
Macro Macro3031
Macro Macro3030
run "$program files$\VideoLAN\VLC\vlc.exe"
3
ShutDownProcess "VLC"
int w=win("" "Shell_TrayWnd")
Acc a.Find(w "PUSHBUTTON" "VLC*" "class=ToolbarWindow32[]id=1504" 0x1005) ;;Win10. On other OS may be different id.
a.Mouse()
mou
or
Macro Macro3031
run "$program files$\VideoLAN\VLC\vlc.exe"
3
ShutDownProcess "VLC"
int w=win("" "Shell_TrayWnd")
Acc a.Find(w "PUSHBUTTON" "VLC*" "class=ToolbarWindow32[]id=1504" 0x1005) ;;Win10. On other OS may be different id.
POINT p; a.Location(p.x p.y)
w=child(a)
ScreenToClient w &p
PostMessage w WM_MOUSEMOVE 0 MakeInt(p.x+5 p.y+5)