Visual Studio IDE Errors


Every now and then I would get an error “An exception occurred while trying to create an instance of…” when trying to open a .aspx page.


This solved it (from DotNetJunkies):

Tip #1: Debug 
Open the project’s properties dialog, set the debug mode to
“program”, apply, set “start application” to your VS.Net IDE (“devenv.exe” in the “Common7
\IDE” directory). Set some breakpoints in your code (constructor, init, onload, etc. – the
more the better 😉 and start debugging. A new IDE will open (empty), you load the project
and then open the form in designer view.

Tip #2: Read my post about user controls (skip the rant about not reading the docs and don’t worry that it’s about controls, not forms)
http://weblogs.asp.net/rweigelt/posts/26262.aspx
The part about the public properties applies to inherited forms, too.

Tip #3: If you’ve got VI working, take a look at
http://weblogs.asp.net/rweigelt/posts/28984.aspx
and the follow-up
http://weblogs.asp.net/rweigelt/posts/32407.aspx
I use VI all the time now and if you keep some basic rules in mind (no magic stuff), it works really reliably.


Leave a Reply

Your email address will not be published. Required fields are marked *