我正在尝试使用外部 mp3 库播放 mp3,在找到文件之前一切都很好。
我已将文件导入到 Eclipse 中,如下图所示。
这是我的错误:
enProblem playing file mpthreetest.mp3
java.io.FileNotFoundException: mpthreetest.mp3 (The system cannot find the file specified)
java.lang.NullPointerException
如有任何帮助,我们将不胜感激。
最佳答案
检查当前执行目录:new java.io.File(".").getAbsolutePath()
会告诉你。
关于java - 文件未找到异常 : Playing an mp3 file with Java/Eclipse,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/22100795/