问题
When I throw an exception from form_load in my C# application it doesn't work when the platform is x64. (it acts as expected for x86)
When I step through the code, I get to the line where the exception it thrown, then it immediately jumps to timer_Tick.
When I create a new project and add this line to form_load: throw new System.Exception("oops!");
For x86 it crashes as expected. For x64 it doesn't crash.
Is there some way to get an application to actually throw from form_load on 64-bit?
回答1:
Nevermind. Looks like this fell into the black hole of MS known bugs...
https://connect.microsoft.com/VisualStudio/feedback/ViewFeedback.aspx?FeedbackID=357311&wa=wsignin1.0
来源:https://stackoverflow.com/questions/1409161/exceptions-ignored-in-form-load-for-x64