/build/static/layout/Breadcrumb_cap_w.png

How can i uninstall Whatsapp application on KACE silently?

We have decided to remove Whatapp from our company devices. Anyone has done this before using KACE?


0 Comments   [ + ] Show comments

Answers (3)

Posted by: AmberSDNB 3 days ago
Blue Belt
0

Never used Whatsapp but online there is a powershell script. 

$var = '"%LocalAppData%\WhatsApp\Update.exe" --uninstall -s'

Start-Process -Verb RunAs cmd.exe -Args '/c', $var

If that doesn't work, locate what the update.exe file is and try to specify that path with the parameters. 
Batch: "PathToWhatsApp\Update.exe" --uninstall -s

Is it installed in the user context (C:\Users\USERNAME\AppData\Local) or system ("C:\Program Files" or "C:\Program Files (x86)")? That will change your approach. 

Posted by: Unsullied 2 days ago
Yellow Belt
0

Hi @Gerald, you may use this powershell script using Winget to remove WhatsApp - Windows Store App silently.
Create an online Kscript running with logged-in user.

# Check if winget is installed
Write-Host "Checking if Winget is Installed..."
If (Test-Path ~\AppData\Local\Microsoft\WindowsApps\winget.exe) {
#Checks if winget executable exists and if the Windows Version is 1809 or higher
Write-Host "Winget Already Installed"
}
Else {
#Gets the computer's information
$ComputerInfo = Get-ComputerInfo

#Gets the Windows Edition
$OSName = if ($ComputerInfo.OSName) {
$ComputerInfo.OSName
} Else {
$ComputerInfo.WindowsProductName
}

If (((($OSName.IndexOf("LTSC")) -ne -1) -or ($OSName.IndexOf("Server") -ne -1)) -and (($ComputerInfo.WindowsVersion) -ge "1809")) {

Write-Host "Running Alternative Installer for LTSC/Server Editions"

# Switching to winget-install from PSGallery from asheroto
# Source: https://github.com/asheroto/winget-in...

Start-Process powershell.exe -Verb RunAs -ArgumentList "-command irm https://raw.githubusercontent.com/asheroto/winget-installer/master/winget-install.ps1 | iex | Out-Host" -WindowStyle NoNewWindow

}
ElseIf (((Get-ComputerInfo).WindowsVersion) -lt "1809") {
#Checks if Windows Version is too old for winget
Write-Host "Winget is not supported on this version of Windows (Pre-1809)"
}
Else {
#Installing Winget from the Microsoft Store
Write-Host "Winget not found, installing it now."
Start-Process powershell.exe -Verb RunAs -ArgumentList "-command irm https://raw.githubusercontent.com/asheroto/winget-installer/master/winget-install.ps1 | iex | Out-Host" -WindowStyle NoNewWindow
Write-Host "Winget Installed"
}
}

# Detect WhatsApp - Windows Store Version
If (Test-Path "$env:LOCALAPPDATA\Packages\5319275A.WhatsAppDesktop_cv1g1gvanyjgm") {
Write-Host "WhatsApp found, attempting to upgrade..."
winget upgrade --Name "WhatsApp" --Id "9NKSQGP7F2NH" -e -s=msstore -h --accept-source-agreements --accept-package-agreements
}
# Detect WhatsApp - Windows Store Version
If (Test-Path "$env:LOCALAPPDATA\Packages\5319275A.WhatsAppDesktop_cv1g1gvanyjgm") {
Write-Host "WhatsApp found, attempting to uninstall..."
winget uninstall --Name "WhatsApp" --Id "9NKSQGP7F2NH" -e --silent --accept-source-agreements
}
Else {
Write-Host "WhatsApp already uninstalled..."
}
Posted by: gerald.tan@mandai.com 2 days ago
White Belt
0

Thank you everyone for the replies. Will try these out. You guys are really helpful.

Don't be a Stranger!

Sign up today to participate, stay informed, earn points and establish a reputation for yourself!

Sign up! or login

Share

 
This website uses cookies. By continuing to use this site and/or clicking the "Accept" button you are providing consent Quest Software and its affiliates do NOT sell the Personal Data you provide to us either when you register on our websites or when you do business with us. For more information about our Privacy Policy and our data protection efforts, please visit GDPR-HQ