“Value does not fall within the expected range!” when trying to load a reference in a project

Prem Murmu on 5/13/2020 8:18:40 AM

Error: I was getting this error "Value does not fall within the expected range" whenever I was trying to add a project reference to main solution.I tried to rebuild my soutions again and again,but not succeded.

I close soutions and reload and tried the change the path of project reference in its .csproj file,but coulnd succeded,finally i got a solution by searching in stack overflow.


  1. Exit Visual Studio
  2. Click Start
  3. Type cmd, right click Command Prompt and select Run as administrator
  4. Navigate to the appropriate Visual Studio folder,I navigation to vs 2019 path

VS2012: programfiles(x86)\Microsoft Visual Studio 12.0\Common7\IDE

VS2015: programfiles(x86)\Microsoft Visual Studio 14.0\Common7\IDE

VS2017: programfiles(x86)\Microsoft Visual Studio\2017\<Edition>\Common7\IDE

VS2019: programfiles(x86)\Microsoft Visual Studio\2019\<Edition>\Common7\IDE

  5. Type devenv /setup and press enter

When the command prompt returns, you're done. Close the command window, reopen Visual Studio, and test to see if the error's resolved.



0 Comments on this post

Comments(0)||Login to Comments

InterServer Web Hosting and VPS
  • see more..