javajdbc.net-6.0

J2NET.Runtime could not be found. Please check if the runtime is installed for your platform


I want to use JDBC.Net.Data on my project. In .Net Core 6 console application it works but when I try it in a .Net Core 6 Web API I get the error below.

"J2NET.Runtime could not be found. Please check if the runtime is installed for your platform."

Everything is similar in both projects.

The problem is, In Web App, Kesrel can't access the JRE files which is included in the bin/debug/net6.0/runtimes folder.

But in my console application, everything is same as web app, even the folder structures.

How can I set my web app to fix this problem?


Solution

  • After many days, I got the solution. Instead of web application project must be a console application and only the .net library must be included.