Empresas
Empregos
  • Sobre nós
  • Soluções
    • Publicação de vagas
      Publique sua vaga e receba candidatos qualificados em 48h.
    • Avaliações de candidatos
      Mais de 500 testes técnicos e psicológicos, mais anti-fraude.
    • Headhunting
      Busca executiva personalizada do início ao fim.
    • Folha de Pagamento + EOR
      Dispersão de folha e EOR em mais de 15 países da LATAM.
  • Preços
  • Empregos

0

466
Visualizações
How to fix `Your project does not reference ".NETFramework,Version=v4.6.1" framework...`

I got this error Your project does not reference ".NETFramework,Version=v4.6.1" framework. Add a reference to ".NETFramework,Version=v4.6.1" in the "TargetFrameworks" property of your project file and then re-run NuGet restore. after checkout a project from company repository and rebuild on my machine.
When I try to install .Net461 (downloaded from here) they said

.NET Framework 4.6.1 or a later update is already installed on this computer.

This is all .NET framework versions on my machine (Windows 10 1703)

PS C:\Users\longnx\Downloads> & '.\check-dotnet-framework-version (1).ps1'

PSChildName                      Version        Release
-----------                      -------        -------
v2.0.50727                       2.0.50727.4927
v3.0                             3.0.30729.4926
Windows Communication Foundation 3.0.4506.4926
Windows Presentation Foundation  3.0.6920.4902
v3.5                             3.5.30729.4926
Client                           4.7.03062      461814
Full                             4.7.03062      461814
Client                           4.0.0.0


PS C:\Users\longnx\Downloads>

How can I fix this error?


update on 2020-05-26:
for anyone face this problem, I don't suggest this but from my experience, I've uninstalled and reinstall visual studio, and problem gone.

over 4 years ago · Santiago Trujillo
3 Respostas
Responde à pergunta

0

The error can be solved by deleting the obj folder. But, if you have more than one project in the solution, targeting and deleting all the obj folders can be burdensome. So you can run this PowerShell command in the root of your code repository (or in the solution folder) to recursively find and delete obj folders and their content.

Get-ChildItem -Filter obj -Recurse -Force | Remove-Item -Recurse -Force
over 4 years ago · Santiago Trujillo Relatório

0

Most of the time when I face this error I just Delete or Rename the OBJ folder and try to run Visual Studio as Administrator (don't make much of difference, but helps when I download project from some tutorial website) and build the Application again.

But if that don't work then check of version of NuGet package compatibility with .net version in project setting/properties page, having to get proper NuGet package and .net version is a must for building and program. Also removing and reinstalling Visual Studio and installing that again is never an option, as it takes time to uninstall and install again.

over 4 years ago · Santiago Trujillo Relatório

0

I found this link from a google search and tried it and it fixed my issue so I thought I might share that deleting the obj folders seems to work.

As it states in forum:

I had the same with an old project (after using git to move to an old version locally). Deleting the 'obj' folders fixed the issue, clean is insufficient.

Two users found that this fix the issue. Most also found doing a clean and then removing the obj folder by hand then redoing a nuget restore seemed to fix the issue.

over 4 years ago · Santiago Trujillo Relatório
Responde à pergunta
Encontrar trabalhos remotos

Descubra a nova forma de encontrar um emprego!

melhores empregos
Principais categorias de trabalho
Empresas
Postar vaga Preços Comercial
Jurídico
Termos e Condições Política de privacidade
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Recomende algumas ofertas para mim
Preciso de ajuda