Field Notes | The Windows 10 1703 Default Apps Minefield

Managing the default application associations in Windows 10 used to be simple, the process was straightfoward and worked without issue. With Windows 10 being released semi-annually you would expect some very minor process differences between versions, however it appears setting default assoications isnt that simple any more.

The method ive used for Windows 10 1511 & 1607 was easy, simply;

  1. Build reference machine
  2. Install applications that will be be default for file types (in my case Acrobat for PDF, Chrome for Web)
  3. Set new application defaults for extensions
  4. Run (elevated) to capture my changes
    Dism /Online /Export-DefaultAppAssociations:\\Server\Share\AppAssoc.xml
  5. Appy the above file either with DISM during OSD, or via Group Policy
    Dism.exe /online /Import-DefaultAppAssociations:\\Server\Share\AppAssoc.xml

It turns out that when attempting to do this with 1703 , you will see “App defaults were reset” on a machine with default applications applied with the above method. The ‘app default reset’ issue may also rear its ugly head even if you dont set file associations, it seems to happen if you have any other application present that has attempted to take control of the extension. In my case when Acrobat was installed it attempted to take control of the PDF extension. Windows seems to have changed the way associations are set in a Windows Update (KB3135173), if an application is not updated to adress this change it may trigger the association to fall back to default. When setting application defaults through the GUI, windows will set a hash value (assume for security) for each extension type.

bngdabh

The first step on the road to make file associations to behave is to take note of the ProgID that is assigned to each extension type by default, this can be achieved by running the DISM /Export command discussed earlier. Below is an export from a stock Windows 10 1703 build. Note PDF is not present until it is modified through the default apps GUI.

Note that the ProgID changes for some applications depending on the extension its referring to, Edge has many ProgID’s

The first trick in building a working default associations file is to follow the same process from before

  1. Install applications that will be be default for file types (in my case Acrobat for PDF, Chrome for HTM/L, HTTP/S,  Outlook for MailTo)
  2. Set new application defaults for extensions (from Settings/System/Default apps)
  3. Run (elevated) to capture changes
    Dism /Online /Export-DefaultAppAssociations:\\Server\Share\AppAssoc.xml
  4. Open your XML in your favourite text editor.
  5. Remove all values except for those you wish to change defaults for

The next step is to take not of each ‘ProgID’ from the ‘stock’ defaults file and add the following to each element above;

ApplyOnUpgrade=”true”
OverwriteIfProgIdIs=”<ProgID>”

Your final product should look something like this;

The XML is now ready for deployment, however this XML will not apply using the DISM method in 1703, when i attempted to apply this file all other application extensions NOT defined would spam the notification centre with messages of ‘app default reset’.

The easiest way to apply this file is via Group Policy. In Computer Configuration\Administrative Templates\Windows Components\File Explorer set the value of DefaultAssociationsConfiguration to \\Server\Share\AppAssoc.xml.

Note: The path must be readable by workstations.

Applying this Policy will allow file associations to work correctly, i noticed that i still saw the painful ‘app defaults reset’ for PDF files only. More on this shortly.

In my enviroment i have a mixed bag of 1511 , 1607 and 1703 versions of Windows 10. Setting a Group Policy for just the 1703 revision would mean a seperate policy targeted to JUST the 1703 revision of Windows (filtered via WMI). I found this messy. I wanted these associations to only apply during builds of 1703. If you are in the same boat follow along.

The Group Policy modifies the registry value of DefaultAssociationsConfiguration in HKLM:\Software\Policies\Microsoft\Windows\System, we can edit this item with our modified XML’s path during OSD. Via PowerShell;

Set-ItemProperty -Path HKLM:\Software\Policies\Microsoft\Windows\System -Name DefaultAssociationsConfiguration -Value '\\Server\Share\AppAssoc.xml'

Add this command to a step in your Windows 10 1703 Task Sequence in SCCM. I have a Windows 10 Modifications PS Script that ive added this to.

As i mentioned previously this method would set defaults just fine, however PDF extensions would still fall back to Edge, to fix this you want to run the following set of commands. (Line 5 , 6 , 7). If you see the fallback behaviour for any other applications, use the same method and adjust for the ProgID in question.

*Note ProgID matches Edge.

These steps will remove Edge from your right click>open with conext menu but will stop Edge from falling back.

** Some have suggested to overwrite OEMDefaultAssociations.xml in System32 with your modified Default XML during OSD, however i had no luck with this.

Hopefully this helps others, there are multiple issues im working through in Windows 10 1703, in no particular order these are;

  • Default app model is broken and does not work via DISM (need to use GPO)
  • OOBE is broken / something went wrong (need to use depreciated Skip OOBE)
  • Start menu does not honour size/orientation if you have more than 1 group
  • The order of quick launch does not work in start menu xml
  • Start Menu doesn’t honour locked sections

I will add a post explaining each of these issues (with workarounds) when i get some time.

Cheers,

Dan

 

2 thoughts on “Field Notes | The Windows 10 1703 Default Apps Minefield

  1. Just for others having the same fun.

    Actually, on Windows 10 build 1703 even the “old” XML works fine without (OverwriteIfProgIdIs) but only for “new users” in the system. For existing ones, seems like the only way is GPO…

    However, since I needed to use it during MDT deployment and built-in Administrator I have edited the vanilla “.WIM” offline.

    dism /mount-image /imagefile:”…\Windows 10 Enterprise x64 1703\sources\install.wim” /index:1 /mountdir:C:\whatever
    dism /Image:C:\whatever /Import-DefaultAppAssociations:..\DefaultApps.xml
    Dism /Commit-Image /MountDir:C:whatever

    Like

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s