1. Install IIS on your computer. This is required.
2. Change the. NET Framework version for your project. The. NET Framework Version corresponding to the application pool must also match.
3. Locate the default website directory on your computer to the web project directory of your project, and check whether your local website is being displayed. Http: // localhost
If not. First, check whether ASP. NET is installed. Register ASP. NET after installation. To register ASP. NET, switch to the administrator user.
If ASP. NET is not registered, a script error is prompted when you open the website.
In the second IIS setting, find the ISAPI and CGI. Allowed ASP. NET versions. If this step is not set, an error will be reported when you open the website.
4. Run vs2010 as an administrator and open your project. Remember to follow the steps I mentioned. Do not double-click it directly in your project. This is not the case.
Find the WEB Project in your project. Right-click "properties" on the server. Check to use the local IIS Web server. Enter http: // localhost in the project URL; Debugger: ASP. NET
OK. Here. You can debug your web project in your local IIS.