简体   繁体   中英

DISM /Import-DefaultAppAssociations runs successfully, but no file associations are changed

On Windows 10, I run

dism /online /import-defaultappassociations:\\path\to\appassociations.xml

The output says the command was completed successfully, but the defaults aren't changed when opening files. The changes are also not visible in Control Panel > Default Programs .

I know the xml is accessible and this command worked on 8.1 computers in our environment. But every Windows 10 computer has had the same issue.

The DISM logs show some warnings, but I cannot really tell if they are related. I can provide them if necessary.

First of all this should probably be on serverfault or superuser since its a systems related (script/batch) question, not really programming (I know they overlap).

dism /import only works for new users on a PC. The GPO I believe works for existing users:

Computer Configuration\\Administrative Templates\\Windows Components\\File Explorer\\Set a default associations configuration file

I'm currently fighting with the pros & cons of each as noted above.

  • GPO con: doesn't really respect/keep users app associations, it resets them back to your GPO ones on each login. You could apply the GPO for a month & disable?
  • GPO con: only works for domain PC's, if you configure it on a local gpedit.msc it will simply not work
  • DISM pro: respects users app associations since I believe it only runs the once (new user setup)?
  • DISM con: as noted above only works for new users. Crappy solution: delete user profile

Also be aware tweaking the appassoc.xml to only include the entries you WANT to change may cause multiple 'an app default was reset' messages for new users (using dism /import or GPO). At the time this appears to be a glitch or unintended side-effect with build 10586 or kb3135173 because of how app associations changed & need unique hashes

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM