The CLR supports module initializers. You’d have to hack C++/CLI code or ilasm.exe to use them.
UPDATE: directly supported in C# as well since .NET 5 with the [ModuleInitializer] attribute
More Related Contents:
- WCF – How to Increase Message Size Quota
- A reference to the dll could not be added
- How to solve “Could not establish trust relationship for the SSL/TLS secure channel with authority”
- Injecting data to a WCF service
- Difference between web reference and service reference?
- How did Microsoft create assemblies that have circular references?
- WCF Service Returning “Method Not Allowed”
- How to load a .NET assembly for reflection operations and subsequently unload it?
- Contract-First SOA: Designing Business Domain: WCF
- Is .NET Remoting really deprecated?
- ServiceRoute + WebServiceHostFactory kills WSDL generation? How to create extensionless WCF service with ?wsdl
- Reports in SOA (Business Intelligence & Service Oriented Architecture)
- WCF: Exposing readonly DataMember properties without set?
- How to use Assembly Binding Redirection to ignore revision and build numbers
- How to prevent Visual Studio from launching WcfSvcHost.exe while debugging?
- Calling a webservice that uses ISO-8859-1 encoding from WCF
- Any way to make DataContractJsonSerializer serialize Dictionaries properly?
- WCF Error “Maximum number of items that can be serialized or deserialized in an object graph is ‘65536’”
- Determine framework (CLR) version of assembly
- WCF service startup error “This collection already contains an address with scheme http”
- Does .NET assembly size affect performance?
- How do I get the version of an assembly without loading it?
- Service has zero application (non-infrastructure) endpoints
- Can I pass non-string to WCF RESTful service using UriTemplate?
- .NET Assembly Diff / Compare Tool – What’s available? [closed]
- How to set keep alive interval for HTTP connection in WCF
- WCF sessions with a wsHttpBinding and without windows security
- WCF is using the computer name instead of the IP address and cannot be resolved
- Managing complex Web.Config files between deployment environments
- WCF Service Throttling