I realise this question and it's variants have been asked before and I've looked through them but am asking this particularly because it's quite urgent and also the answers didn't seem to quite fit.
I have a set of dll's which contain functions to load/extract data from oracle. Due to a whole load of reasons, I'm having to dynamically call them from a .net exe using Reflection.
Now, when I try running the dll through MSDev, it connects to Oracle fine but when I try to invoke it using reflection from the exe (I made sure I referenced the same dll (from debug path) in my exe for test purposes) it throws a provider not compatible error.
In the dll project, I bundle the Oracle.DataAccess.dll along with other necessary dlls (OraOps11w.dll,oci.dll?) with the setup so they are all in the same path.
For some reason I get this error during dynamic invocation. some of my team members seem to get it even otherwise on their machines. Don't understand why it should mismatch dll's when all of the necessary one's are avaialble in the same path.
Any ideas please? (will reply tomorrow)
System.TypeInitializationException was unhandled
Message="The type initializer for 'Oracle.DataAccess.Client.OracleConnection' threw an exception."
at Oracle.DataAccess.Client.OracleConnection.Dispose(Boolean disposing)
Message="The provider is not compatible with the version of Oracle client"
Source="Oracle Data Provider for .NET"