Jump to content

Remove Windows Apps for All Users


ViciousXUSMC
 Share

Recommended Posts

I have messed with this time to time, but recently decided to go ahead and push it out because I have so many people having the default reader app take over adobe and since they are not admins they cant easily change the default program to adobe for their profile.

To remove the app for the current user I use.

get-appxpackage | where name -like '*reader*' | remove-appxpackage

If it is a new computer build I can remove the app from the system so it does not install for any new users with this.

get-provisionedappxpackage -online | where displayname -like '*reader*' | remove-appxprovisionedpackage -online

So where I am stuck is getting it off existing accounts on computers in the field.  Every article, document, etc I can find says all you need to do is add the -allusers flag.

If I add the flag to the get package part it does show the package for each user, but when I pipe it into the remove-package cmdlet I get an error that the package is not installed for the current user and it does not uninstall it for any other account.

This is what I have tried:

get-appxpackage -allusers | where name -like '*reader*' | remove-appxpackage

Also a revision of it

get-appxpackage -allusers *reader* | remove-appxpackage

As far as I can tell, this is correct but simply is not working. 

Any ideas or anybody know what the key issue that I am overlooking is?

Link to comment
Share on other sites

  • Moderators

Have you tried something like this?

Get-AppxPackage -allusers -Name *reader* | Remove-AppxPackage

 

"Profanity is the last vestige of the feeble mind. For the man who cannot express himself forcibly through intellect must do so through shock and awe" - Spencer W. Kimball

How to get your question answered on this forum!

Link to comment
Share on other sites

  • 2 weeks later...

You know, there are scripts available on Microsoft's script repository that might be of help.  I would try these:
https://gallery.technet.microsoft.com/scriptcenter/Remove-Windows-Store-Apps-a00ef4a4

https://gallery.technet.microsoft.com/scriptcenter/Windows-10-Store-Apps-5f60b9e3

http://www.thewindowsclub.com/10appsmanager-windows-10

These might get you to where you need to be.

Edited by MattHiggs
Link to comment
Share on other sites

  • 2 weeks later...

You must be trying on a system with the 1511 Windows update. I've been working with this extensively and the behavior you described seems to be unique to Windows build 1511. The command you provided it works on previous builds, and it works on the new 1607 anniversary update.

First off for these purposes "allusers" is not allusers in the conventional sense like the All Users folder was in previous versions of Windows. When you run the get-appxpackage command with the -allusers switch it's simply spitting out a list of apps which exist in one or more user profiles on the computer.

get-appxpackage -allusers | where name -like '*reader*' | remove-appxpackage

For any version other than 1511 the command behaves something like this:
Generate a list of apps installed all user profiles. If '*reader*' exists remove it from ANY profile in which it exists.

For some reason in build 1511 the command behaves this:
Generate a list of apps installed on all user profiles. If '*reader*' exists remove from the current user profile only.

I have yet to find an eloquent solution for removing apps from all users in 1511, but at least it's fixed in 1607. I know this doesn't really help, but hopefully provides some insight as to why it's not working for you.

 

Link to comment
Share on other sites

  • 2 weeks later...

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

×
×
  • Create New...