新创建了一个项目,编译运行时报错:
Cannot start compilation:the output path is not specified for module “com.mycode.connection”. Specify the output path in the Project Structure dialog.
这里是因为没有为模块“com.mycode.connection”指定输出路径(这个路径目录是源码编译后Class文件的存放目录)。
解决方法:
在project structure(项目结构)的project settings里选中project,然后在Project compiler output选择项目中的out文件夹(如果在项目文件夹下没有out文件夹,可以自己创建一个,这次报错就是这种情况)
Java源代码编译成Class文件的输出路径: