Error in Eclipse Java/Windows
AnsweredHello, I have a problem with using gurobi in my eclipse project. I already searched on the internet and did everthing which was suggested but nothing helped.
Error: java.lang.NoClassDefFoundError: com/gurobi/gurobi/GRBException
Steps I did already: - get an licsense and tested it
- add a new System variable on my pc named GRB_LICENSE_FILE, and set it to the location of your license file
- Eclipse: Java build path -> included gurobi.jar -> it is listed correctly in referenced libraries
- Eclipse: setted up enviroment variables in run configurations, tried PATH, CLASSPATH, LD_LIBRARY_PATH and tried to link them to the lib folder of gurobi as well as to the general folder of gurobi
- Eclipse: tried the line "import com.gurobi.gurobi.*;" and "import gurobi.*;" in my programming
Nothing of these steps helped. I would really appreciate any help to solve this problem.
Thank you in advance.
-
Official comment
This post is more than two years old. Some information may not be up to date. For current information, please check the Gurobi Documentation or Knowledge Base. If you need more help, please create a new post in the community forum, or try Gurobot, our chatbot interface offering instant, expert-level support. -
Hi Marcus,
I'll open up a Support Request for this since it relates to installation.
You'll receive an email to this effect shortly.
- Riley
0 -
Hi Marcus,
Although the Support Request is closed my advice is to adjust your environment variables:

On a Windows machine you will only need PATH. As per How do I use Gurobi in an Eclipse Java project? you should set this to C:\gurobi1101\win64\bin
- Riley
0 -
Hello Riley,
thank you for your answer.
I have solved the problem: I had to import the gurobi.jar in the classpath and not the modulepath.
Thank you very much for all your support.
Kind regards,
Marcus Scheutz
0
Post is closed for comments.
Comments
4 comments