Visual studio 2022 - The IIS Express applicationHost.config file contains invalid entries and must be corrected before you can open project

Shunmuga Priya Kandasamy (INFOSYS LIMITED) 131 Reputation points Microsoft Vendor
2022-01-27T09:32:28.76+00:00

Hi Team,

The microsoft visual studio 2019 web and webapi projects when opened in visual studio 2022, getting the below error and cannot open it.Please guide me

The IIS Express applicationHost.config file contains invalid entries and must be corrected before you can open project

169031-image.png

Internet Information Services
C#
C#
An object-oriented and type-safe programming language that has its roots in the C family of languages and includes support for component-oriented programming.
10,569 questions
{count} votes

1 answer

Sort by: Most helpful
  1. Ken Tucker 5,846 Reputation points
    2022-01-27T10:25:42.01+00:00

    In the folder your solution is in delete the hidden folder .vs and try again. This will cause the file to be regenerated when you open the solution again.

    0 comments No comments