Kai Inkinen
Kai Inkinen

Reputation: 2631

Win8: Registration of the app in the layout folder ... failed

Noob warning. I'm really new to Windows dev tools.

I've got the latest Win8 RC installed, and got VS 2012 RC for it as well. Now I'm trying to create a Metro-style application (C#), but running into problems when executing tests from VS. The error message is:

Error : DEP0700 : Registration of the app in the layout folder "C:\<FOLDER>" failed. 

error 0x80070005: Failed to set access rights to \\?\C:\<FOLDER>

Failed to activate Metro style unit test executor. Error : The parameter is incorrect.

If trying to run the unit tests from the command line using vsttest.console.exe, initially it failed because of an untrusted root certificate. The remedy was to add the generated .cer-file using Certutil, and after that running unit tests from the command prompt worked as expected.

However, Visual Studio still refuses to run the tests with the same error message. The *\?* in the path looks like invalid, but I don't have enough experience with VS to know whether it's normal or not. I also tried the instructions found here and here, but without any use.

Running

Get-WinEvent -logname Microsoft-Windows-Appx* |Select-Object -first 10|Out-GridView

says that "The last successful state reached was PrerequiesitesCheced", but otherwise gives me more or less the same "Failed to set access rights" error as above.

Some more background info:

Has anyone got a similar situation, and managed to fix it somehow? Any help would be greatly appreciated.

Upvotes: 5

Views: 4157

Answers (3)

SynerCoder
SynerCoder

Reputation: 12776

In my case it turned out to be the fact that I have every folder encrypted. To run the application I had to disable encryption for the complete solution folder (and subfolder/files).


How to:

First right click the folder then properties:

dropdown menu

Then clicked advanced:

folder properties

Then deselect

Encrypt contents to secure data

advanced

At last, click apply. You are then asked where to apply the changes to. Select

Apply changes to this folder, subfolders and files

apply changes

Now you are done.

Upvotes: 1

Kai Inkinen
Kai Inkinen

Reputation: 2631

We never managed to figure out a reason for this, and in order to save time I finally wiped the whole environment, and ended up re-installing windows. I'm using a dedicated machine for this, and MS has made the installation process very easy, so this was not a big deal. Problems with the pre-release I guess, because I haven't encountered a similar problem anymore, and neither has anyone else on my team.

Upvotes: 0

I solved this by changing the package name by app manifest

Upvotes: 2

Related Questions