当前位置: 代码迷 >> J2SE >> 请大伙儿帮下忙
  详细解决方案

请大伙儿帮下忙

热度:92   发布时间:2016-04-24 13:13:43.0
请大家帮下忙!
import org.jdesktop.jdic.desktop.*;
import java.net.*;
public class DesktopTest {
public static void main(String[] args) throws Exception {
Desktop.browse(new URL("http://www.yahoo.com/"));
}
}

运行上面的程序时,为什么会出现下面的错误?
Exception in thread "main" java.lang.UnsatisfiedLinkError: no jdic in java.library.path
at java.lang.ClassLoader.loadLibrary(Unknown Source)
at java.lang.Runtime.loadLibrary0(Unknown Source)
at java.lang.System.loadLibrary(Unknown Source)
at org.jdesktop.jdic.desktop.internal.impl.WinAPIWrapper.<clinit>(Unknown Source)
at org.jdesktop.jdic.desktop.internal.impl.WinUtility.getVerbCommand(Unknown Source)
at org.jdesktop.jdic.desktop.internal.impl.WinBrowserService.show(Unknown Source)
at org.jdesktop.jdic.desktop.Desktop.browse(Unknown Source)
at DesktopTest.main(DesktopTest.java:6)



------解决方案--------------------
可能是环境配制出问题了吧
------解决方案--------------------
你有没有加jdic.jar呢?
错误提示: no jdic in java.library.path
------解决方案--------------------
你需要添加下这个文件的引用
  相关解决方案