GetReferenceNearestTargetFrameworkTask not found

Ranorex Spy, Recorder, and Studio.
Posts: 4
Joined: Thu Oct 31, 2019 4:24 pm

GetReferenceNearestTargetFrameworkTask not found

Post by jonny » Fri Mar 20, 2020 4:07 pm

This question is in relation to ... 15733.html. I had been RDP'ing into my other system due to the current health situation. But to address the response in that question. I uninstalled my license and installed the latest version 9.3.1 of Ranorex to my Windows 10 machine so I don't have to RDP in. This is a fresh install and I started a new project. Unfortunately, to test whether this fixes the linked question above, I am getting this error?
The "GetReferenceNearestTargetFrameworkTask" task was not found. Check the following: 1.) The name of the task in the project file is the same as the name of the task class. 2.) The task class is "public" and implements the Microsoft.Build.Framework.ITask interface. 3.) The task is correctly declared with <UsingTask> in the project file, or in the *.tasks files located in the "C:\Program Files (x86)\Microsoft Visual Studio\2017\BuildTools\MSBuild\15.0\Bin" directory. (MSB4036) - C:\Program Files (x86)\Microsoft Visual Studio\2017\BuildTools\MSBuild\15.0\Bin\Microsoft.Common.CurrentVersion.targets:1657,5
I am running Ranorex as an admin additionally



Posts: 20
Joined: Wed Sep 18, 2019 9:19 am

Re: GetReferenceNearestTargetFrameworkTask not found

Post by foals11 » Mon Mar 23, 2020 8:46 am


Try both solutions that are mentioned in this stackoverflow post? Try to install the NuGet targets and build tasks and the NuGet package manager from the Visual Studio installer. ... -not-found


Posts: 4
Joined: Wed Apr 08, 2020 7:26 am

Re: GetReferenceNearestTargetFrameworkTask not found

Post by NehaMavani » Fri Apr 10, 2020 8:32 am

Hi. Ikeep facing the same problem. Tried both the solutions. Didn't work. Do we have any other alternative here?

User avatar
Certified Professional
Certified Professional
Posts: 222
Joined: Mon Jul 11, 2016 2:15 pm

Re: GetReferenceNearestTargetFrameworkTask not found

Post by Vega » Thu Apr 16, 2020 12:27 am

Is this showing as a warning or an error when you try to build? Do you know if you happen to have the 4.6.2 developer pack installed? ... loper-pack

hope this helps