Visual Studio Error: Creation of the virtual directory http://localhost:62498/ failed with the error: Filename: \\?C:…

created at 01-08-2022 views: 3

The project is uploaded to the "team fundation server", and the following error occurs after other people take it out.

Error: Cannot write configuration file due to insufficient permissions.

You will need to manually create this virtual directory in IIS before you can open this project.

I looked at the solution to the corresponding problem from stack overflow, and roughly understood the cause.


The downloaded directory is inconsistent with the uploader's directory.


In the .vs folder in the project folder, find the config folder, open the applicationhost.config file under the config folder, find the following code after opening, and modify the following absolute path to The absolute path on the downloader's computer can be saved later (the kid's project files are all stored in the VisualManagement folder), and it is completely normal after opening.

<application path="/" applicationPool="Clr4IntegratedAppPool">
    <virtualDirectory path="/" physicalPath="C:\ABC\IT.ABC\Global\WebApplication\VisualManagement\VisualManagement" />
created at:01-08-2022
edited at: 01-08-2022: