views:

217

answers:

3

When loading up a solution in VS2008 I get this message:

An error was encountered while opening associated documents the last time this solution was loaded. Document load is being skipped during this solution load in order to avoid that error.

It shut down immediately the first time I opened it. The next time I opened it, VS popped up a message box but did not shut down at first; however, it did shut down when I clicked a usercontrol or ASPX page.

How can I find which document is causing the problem?

Thanks...

+1  A: 

Open your documents one at a time until it crashes.

Once you isolate the crash, you can open a second copy of VS and attach its debugger to the first copy, then crash it and look at the exception in the second one. (Use Debug, Exceptions to break on all exceptions)

SLaks
for why I am getting this excpetoin due to wat reasons, bec since half an hour back I am working fyn.. Thanks
kumar
+1  A: 

There is a lot going on in VS, especially when a bunch of designers are open when you closed last or perhaps a dirty close.

Try to keep the number of documents you have open when you close a solution to a reasonable number.

Bottom line is: It happens. Unless it becomes a regular occurrence you should not worry too much. If you consistently crash follow SLaks advice.

Sky Sanders
Frankly speaking I dint understood what Slaks sujjsted to do?thanks can you help me out..
kumar
+1  A: 

This seems to be related to other view-launch bugs that have been in Visual Studio since VS6.0, by my recollection.

One workaround that usually works for me for VS2003-VS2010 is to delete the .SUO file corresponding to the solution file. In VS6.0, you may also have to delete the .NCB file as well.

There are other reports of similar VS solution launch bugs in Microsoft Connect. Here's a ticket relating to a similar bug in VS2010, which I believe is the same as your issue.

"error on loading solution 100% of the time" @ Microsoft Connect

meklarian