Home
Help
Register
Log in

Search

 
   Active Threads  

You are here: Home > ORM Profiler Section > Bugs & Issues> Can't initialize
 

Pages: 1
Bugs & Issues
Can't initialize
Page:1/1 

  Print all messages in this thread  
Poster Message
etail
User



Location:

Joined on:
09-Apr-2015 17:11:03
Posted:
1 posts
# Posted on: 09-Apr-2015 17:16:40.  
I am changing the application config file using:

AppDomain.CurrentDomain.SetData("APP_CONFIG_FILE", "evp.config");

If I place the InterceptorCore.Initialize before this statement, it causes the config to not change and then my app to fail. If I place it after, then the initialization fails and I don't get anything in the profiler.
  Top
Otis
ORM Profiler Team



Location:
The Hague, The Netherlands
Joined on:
22-Aug-2011 10:26:38
Posted:
611 posts
# Posted on: 10-Apr-2015 09:09:28.  
etail wrote:
I am changing the application config file using:

AppDomain.CurrentDomain.SetData("APP_CONFIG_FILE", "evp.config");

If I place the InterceptorCore.Initialize before this statement, it causes the config to not change and then my app to fail. If I place it after, then the initialization fails and I don't get anything in the profiler.

Hmmm. All the initializer does is overwrite the DbProviderFactory table and that's it. The call you mentioned does trigger static constructors, I don't know whether you have some of them in scope, they might run when the call above is made, so if the initializer is then run after that it might be too late due to a static constructor already having obtained the dbproviderfactory.


Frans Bouma
ORM Profiler / LLBLGen Pro Lead Developer | Blog | Twitter
 
Top
Pages: 1  


Powered by HnD ©2002-2007 Solutions Design
HnD uses LLBLGen Pro

Version: 2.1.09082011 Final.