- 02 Feb 2024
- 1 Minute to read
- Print
- PDF
Force close apps on Windows devices
- Updated on 02 Feb 2024
- 1 Minute to read
- Print
- PDF
At times, devices may experience situations that necessitate users to close currently active applications. This might be due to factors such as utilizing an outdated app version, running an excessive number of applications simultaneously, facing space constraints, or encountering instances where the app has stopped running altogether.
The following PowerShell script helps the IT Admins to remotely force stop the currently running application on managed Windows devices.
Create a file on your desktop, for example, force_close_app.ps1 and open it in a text editor like notepad++
Copy the contents below to the file or click here to download the file.
stop-process –name <Name of the app to be closed> -force
To close the Notepad++ app, add the name of the app as below:
stop-process –name notepad++ -force
Follow our guide to upload & publish the PowerShell script using Scalefusion Dashboard.
Please note that to use the PowerShell scripts, the Scalefusion MDM Agent Application must be installed on the device(s). Please follow our guide to publish and install the Scalefusion MDM Agent Application.
Notes:
The scripts and their contents are sourced from various albeit authenticated Microsoft sources and forums.
Please validate the scripts on a test machine before deploying them on all your managed devices.
Scalefusion has tested these scripts, however, Scalefusion will not be responsible for any loss of data or system malfunction that may arise due to the incorrect usage of these scripts.