1

I'm having a bizarre problem with Visual Studio 2008. I wanted to debug one of the libraries that my web application references. Therefore, I decide to add the project containing the library to my solution so that I can debug them together.

The project containing my library sits at c:\webLibs\myproj.vbproj. However, when I try to add the project to my solution, Visual Studio throws the following error: "The project file 'c:\someOtherFolder\myproj.vbproj'. has been moved, renamed, or is not on your computer."

As you can see, VS appears to be trying to open a different file than the one I clicked on. I used to have the file in that other location, but not anymore.

I've tried restarting VS several times.

What could cause this bizarre behavior? Why would Visual Studio try to open my project from the wrong folder?

1
  • Thanks for the answers! I had no idea what to do, but now I have something to try tomorrow. Commented Jun 17, 2010 at 22:06

4 Answers 4

2

Try searching for any .suo or .user files in your source hierarchy, especially in your solution's directory. VS stores hints in those files form time to time that can get things out of sync now and again.

1

I found the problem. I had an errant TFS Source-Control mapping that mapped the project to a non-existent folder on the hard drive.

My web application is in its own workspace. The library that I wanted to reference is in its own workspace where it is mapped to c:\webLibs\myproj.vbproj. However, in the web application's workspace, there was an errant mapping to c:\someOtherFolder\myproj.vbproj.

I deleted the errant mapping and everything worked fine :-)

I believe the moral of the story is to check mappings in all workspaces possibly involved when this sort of thing comes up.

0
1

I fixed this by closing Visual Studio, deleting the .suo file then reopening Visual Studio.

0

Sounds like some wires got crossed and Visual Studio's internal project reference for that project is incorrect. You can clean it up if you are good with your registrys, or you can use a simple tool like this one (I use and like this, it's not mine) to remove the bad project (and later re-add the good one).

1
  • I have used it for my VS2008 and it performed just fine.
    – rlb.usa
    Commented Jun 21, 2010 at 7:11

Not the answer you're looking for? Browse other questions tagged or ask your own question.