IIS Express 8 - Cannot write configuration file

后端 未结 12 1347
心在旅途
心在旅途 2021-01-01 09:16

I am trying to use IIS Express 8 for a MVC site in VS2012. I am getting the following error whenever I attempt to create the site:

Filename: \\?\\C:

相关标签:
12条回答
  • 2021-01-01 09:57

    For anyone googling this; this might be the same problem as this: http://connect.microsoft.com/VisualStudio/feedback/details/878812/use-iis-express-is-broken-in-vs-2012-on-windows-8-1

    You can check it by downloading Prcocess Monitor and run it with a filter for "Path" contains "\Documents\IISExpress\config" and then try to change the project to use IIS Express. If there is a CreateFile entry with the result 0xC0190052 as one of the last entries then this is the same issue.

    0 讨论(0)
  • 2021-01-01 10:03

    I'm also in a corporate environment with Encryption on the users folder, and removing encryption and removing the read only flags on everything in the IISExpress folder worked for me.

    0 讨论(0)
  • 2021-01-01 10:03

    In my case I moved the folder to another location, so I had to edit the applicationhost.config file and changed the virtualdirectory entry to the new location. Removing encryption and setting read only off did not help. I imagine if I had just copied it instead of moving it, it would have happily continued working.

    0 讨论(0)
  • 2021-01-01 10:07

    I'm using Visual Studio 2017 on Windows 10 and to fix this problem I had to disable the OneDrive setting "Save space and download files as you use them". After changing the setting my computer crashed but after rebooting I was then able to change SSL Enabled and everything worked.

    0 讨论(0)
  • 2021-01-01 10:07

    I received the same error but in a different context. Opening a project (.csproj file) provided by another developer returned this error and failed to do anything:

    Creating of the virtual directory http://localhost:58753/
    failed with the error: Filename: \?\C:\Users\xxxxx\Documents\Clients\xxx\Gen II\xxx\,vs\config\applicationhost.config Error: Cannot write configuration file

    I removed both Encryption and the R/O attribute from the directory containing the project files and applied to all subfolders and files. Visual Studio can now read the project.

    0 讨论(0)
  • 2021-01-01 10:08

    C:\Users\xxxxxx\Documents\IISExpress\config\applicationHost.config

    Uncheck the read-only attribute from the file. It worked for me.

    0 讨论(0)
提交回复
热议问题