It seems Windows 10 comes pre-loaded with broken access rights these days (build 1803), something that can break opening any (or all) “Modern UI” applications at any point, including the Microsoft Store itself… I have been fruitlessly hunting the intertubes for a solution to this, but all I can find are old posts that does not quite match the current situation, or at least not MY situation.
It took entire days to figure this out, so I share it in case it could be useful for others. The problem is the broken permissions for the Program Files\WindowsApps folder (you will need to show hidden objects in the file system to see it). Or more specifically the permissions for the “Users” group. I guess you are one…
Click Properties/Security/Advanced/Permissions/Users/Show to get the dialog box showing the broken entry. Yes, even Microsoft themselves diagnose the entry as broken… Still they do not fix it. I believe everyone has this error, but it may or it may not cause actual problems. If the bug has bit you, you will have to delete and recreate the entry (as also the dialog box points out) to fix it.
However that is easier said than done because you are not the owner of that folder. So you will have to first take ownership of it (and all its subcontainers). But then it should work, just be sure to adhere to any messages you get while doing this process. (And after everything is done you should probably set the owner back to TrustedInstaller…)
So when the permissions are ok again we’re all good to go, right? Well maybe if you are extremely lucky, but alas for me a reinstall of all the Microsoft Store apps was still needed. After a reboot, the Microsoft Store should come back by itself though, it will automatically reinstall when you try to open it (be patient).
The other apps can then be reinstalled using the following PowerShell command (all on one line):
Get-AppxPackage -AllUsers| Foreach {Add-AppxPackage -DisableDevelopmentMode -Register “$($_.InstallLocation)\AppXManifest.xml”}
After this everything should eventually start working again (maybe another reboot?).