I have created a C# project(dll) that I need to call from java. The C# project has dependendecies (dlls) that were compiled using c2.0 of .net. The machine am using has been installed with .net 4.5. I am compiling the C# project using .net 3.0 and generates the dll. I am using jni4net to call the C# dll (functions) in java but I keep on getting this error. "System.IO.FileLoadException: Mixed mode assembly is built against version 'v2.0.50727' of the runtime and cannot be loaded in the 4.0 runtime without additional configuration information."
Here is my java code.
Bridge.setVerbose(false);
Bridge.init();
Bridge.setClrVersion("v20");
Bridge.LoadAndRegisterAssemblyFrom(new File(""));//path to the .net dll generated using proxygen.exe
Bridge.setVerbose(true);
My Question is Can I load the App.config from java or is there a way in windows or within java to enable the program pick .net 3.5?