Zend certified PHP/Magento developer

How to Set Default Apps on Windows 10 with a script

I am in an enterprise environment and I am trying to set the default apps on several systems by using a .bat script. This is what my script is doing, nothing complicated.

@ECHO OFF
dism /online /Import-DefaultAppAssociations:"%~dp0MyDefaultAppAssociations_Modified.xml"

However, I have noticed that it works on some work stations on not on others. Any ideas on what would be causing that? The only thing I could think of is that the Program IDs in the XML file may change from computer to computer but I can’t imagine that is the case. Any ideas or other methods on how to accomplish setting default apps are welcome.

UPDATE: This script will either work complete and properly or it will not work at all. I have yet to see it where it only updates certain default apps.