How to resolve configuration error of 'targetFramework'?

You may face the below error while running on your ASP website which targeting to the application pool with ASP.NET 2.0 and in this case you will need to change the application pool to use ASP.NET 4.0. Also, make sure your ASP.NET 4.0 is registered with IIS. 

         

Steps to Change Application Pool of a Website from IIS:

  1. Login to your VPS.

  2. Open Start > Administrative tools > IIS Manager.

  3. Expand the “Sites” folder from left-side panel.

    IIS Sites

  4. Select the particular website which is facing 'targetFramework' error.

  5. Right click on the Website and select Manage Web Site > Advanced Settings, as shown in following image:

    IIS Website Advanced Settings

  6. Change the ‘Application pool’ to ASP.NET 4.0 as below.

    Change the Application Pool of a Website

  7. Click on OK command button.

    Save the Changes of Application Pool

Another Way to Change Application Pool is as below:

  1. Open Start > Administrative tools > IIS Manager.

  2. Click on Application Pools and select the dedicated application pool (Only if website is having dedicated application pool) as shown in following image:

    Select Dedicated Application Pool to Make Changes

  3. Set the version of ASP.NET to 4.0, as shown in following image:

    Edit ASP.Net Version in Dedicated Application Pool

  4. Click on OK command button.


Note: If you are having a control panel then we recommend you to change the application pool from there.

 


Related Articles

How to export an SSL certificate from Windows server?

Following are the steps to Export an SSL Certificate from the Windows Server: Open IIS...

How to Backup/Restore IIS7 Configuration?

IIS 7 automatically makes history snapshots of ApplicationHost.config each time a change is...

How to change application pool of a website from IIS?

While you add a website from IIS Manager, you’ll get an option to select the application pool. In...

What SMTP Settings Should I Use in web.config file?

In web.config SMTP settings, you can use your existing email address (whose authentication you...

How to generate CSR key and install SSL certificate on IIS 8?

SSL (Secure Sockets Layer) is an encryption technology, which creates an encrypted connection...

  • 2 Users Found This Useful

Was this answer helpful?