第一步:添加cplex.jar
File -> Project structure -> Modules (name: project name) -> add (+) cplex.jarCplex.jar的安装目录:D:\Program Files\IBM\ILOG\CPLEX_Studio128\cplex\lib第二步:配置 -Djava.library.path
Run -> Configurations -> VM options 添加 -Djava.library.path="D:\Program Files\IBM\ILOG\CPLEX_Studio128\cplex\bin\x64_win64"第一步:添加ILOG_CP.jar
File -> Project structure -> Modules (name: project name) -> add (+) ILOG.CP.jarILOG_CP.jar的安装目录:D:\Program Files\IBM\ILOG\CPLEX_Studio128\cpoptimizer\lib第二步:配置 -Djava.library.path
Run -> Configurations -> VM options 添加 -Djava.library.path="D:\Program Files\IBM\ILOG\CPLEX_Studio128\cplex\bin\x64_win64;D:\Program Files\IBM\ILOG\CPLEX_Studio128\cpoptimizer\bin\x64_win64"原文:https://www.cnblogs.com/liuyingsme/p/13390572.html