Reputation: 27
I want to debug my own UWP programs and I have to replace the dlls in the installed location. But I cannot replace or add any files into the folder because the permissions is denied, how can I do that? I have tried many ways such as take ownership or sign as administrator, but none of them works. Any help will be highly appreciated
Upvotes: 0
Views: 8653
Reputation: 39102
You can access the files inside the WindowsApps folder but only in read-only manner. While it is technically possible to replace files of an app, it is not possible to replace files of an installed app. This would break the integrity of the package and that is verified before the app is launched by the system, so any modification will cause the app not to launch successfully.
However if you just want to access the folder, you can follow the instructions on my brother's blog or here.
All changes below are at your own risk, as you are modifying the permissions of a system folder and that could potentially cause issues
Go to C:\Program Files
and right click the WindowsApps
folder. Select Properties and go to Security tab. Click the Advanced button. Click the Continue button to give yourself administrative permissions.
Next, click the Change button to change the owner and in the newly opened dialog's "Enter the object name to select field enter your username or e-mail (in case you use Microsoft Account). Finally apply the setting on subcontainers by checking the Replace owner on subcontainers and objects field.
Now click Apply and wait until the permissions are granted for all existing items and that should do it :-) .
Upvotes: 2