IntelliJ IDEA Scratch 中的“找不到符号”错误

mFe*_*ein 3 intellij-idea

我试图在来自 IntelliJ IDEA 的 Scratch java 文件中运行一些代码,但是一旦我在我的项目中添加了一个类并尝试运行它,我就会收到以下错误:

Error:(1, 45) package com.example does not exist
Error:(11, 9) cannot find symbol
  symbol:   class MyClass
  location: class Scratch
Run Code Online (Sandbox Code Playgroud)

如何在 Scratch 文件中使用我的项目类?

And*_*rey 11

确保 Scratch Run 配置包含在Use classpath of module下拉列表中指定的模块,该模块定义了这些类: 在此处输入图片说明


归档时间:

查看次数:

1719 次

最近记录:

5 年,2 月 前