Hi,
Long Version with potentially superfluous details:
I have a C# project that I use as a library for multiple programs (The point being it has be tested to and functioned properly). However with my latest program it has been giving me problems. From a static constructor on a custom form I call a static methods of a Config class. This is when I get a TypeInitalizationException from the Config class. The inner exception is a SecurityException which according the stack trace is from "System.Reflection.Assembly.get_Location()" called from Config's constructor. I have never heard of this method and don't call it in Config's constructor (do use other parts of Reflection.Assembly). The weirdest part is that if I put a breakpoint in the first line of the constructor the exception is thrown before it can get there.
Short Version:
A static constructor is throwing an error from an System.Reflection.Assembly method I don't call and a breakpoint of the constructor on the first line isn't reached.
I can post code but there is alot of it and I'm not entirely sure where the problem code is.