D4koon / WhatsappTray

Minimize Whatsapp Desktop-Client to Tray
GNU General Public License v3.0
388 stars 30 forks source link

Exit without showing a dialog (or option) #6

Closed rejhgadellaa closed 7 years ago

rejhgadellaa commented 7 years ago

I wrote a little batch file that launches WA and then the tray service. It works pretty well. I just added a line that exits the service to make sure it all works but I get an annoying dialog saying something like "WAtray exited". Is this really necessary?

In case anyone is interested, this is what I use:

@echo off
cls

:kill_systray
call taskkill /im WhatsappTray.exe
REM start Release.V1.2\WhatsappTray.exe --exit

:start_wa
echo Starting WhatsApp..
"C:\Users\[username]\AppData\Local\WhatsApp\Update.exe" --processStart WhatsApp.exe
if errorlevel 1 goto err

:start_systray
echo Starting system tray agent..
timeout 10 > NUL
start Release.V1.2\WhatsappTray.exe --closeToTray
if errorlevel 1 goto err
echo ..OK
echo.

:done
goto end

:err
echo.
echo An error occured :(
pause

:end
D4koon commented 7 years ago

I removed the messages in the process of #5 Sidenote: With the new version you dont need the script any more becaues WhatsappTray should handle everything.