Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
HomeAnnouncementsFree MagazinesWhite PapersSubmit Content
Discussion GroupsASP.NETWindows FormsLanguages.NET FrameworkVisual Studio.NET
Articles.NET FrameworkASP.NETToolsWindows Forms
.NET DirectoryOpen Source ProjectsUser GroupsWeb Resources
Related Topics
Visual Basic 6SQL ServerMS AccessOther DB ProductsMS Server ProductsMore Topics ...

.NET Forum / Languages / C# / September 2007

Tip: Looking for answers? Try searching our database.

Invalid cast expection but can't find where error is

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
Susan - 24 Sep 2007 20:08 GMT
I am in the process of upgrading my application to Visual Studio 2005 and the
.Net 2.0 Framework. When I run my application in Debug, I get several hundred
lines of the following message in the Output View:
"A first chance exception of type 'System.InvalidCastException' occurred in
mscorlib.dll"
I am never informed of where the error is being thrown. I just get several
hundred lines of the same message. Any ideas of how to resolve this? The
application seems to be running fine, but I am worried that I just haven't
found the effects yet.

Thank you,
Susan
Nicholas Paldino [.NET/C# MVP] - 24 Sep 2007 20:18 GMT
Susan,

   If your app isn't terminating, then it is more than likely something you
don't need to worry about, as there is an exception handler that is catching
the exception and processing it.  See the following thread for an
explaination about what first chance exceptions are as well as how you can
track them down:

http://forums.microsoft.com/MSDN/ShowPost.aspx?PostID=142215&SiteID=1

   Here is some more information about first chance exceptions as well:

http://blogs.msdn.com/davidklinems/archive/2005/07/12/438061.aspx

Signature

         - Nicholas Paldino [.NET/C# MVP]
         - mvp@spam.guard.caspershouse.com

>I am in the process of upgrading my application to Visual Studio 2005 and
>the
[quoted text clipped - 11 lines]
> Thank you,
> Susan

Free Magazines

Get these publications absolutely FREE for up to 12 months. There are no hidden fees and no obligation. Simply choose a title, complete the application form and submit it. Read more ...

Oracle MagazineNetwork ComputingComputer WorldBio-IT WorldeWeekInformation WeekInfosecurity
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.