当前位置: 代码迷 >> Eclipse >> Browser browser = new Browser(shell, SWT.MOZILLA);解决思路
  详细解决方案

Browser browser = new Browser(shell, SWT.MOZILLA);解决思路

热度:858   发布时间:2016-04-23 01:23:37.0
Browser browser = new Browser(shell, SWT.MOZILLA);
其实就是想内嵌一个    Firefox进    SWT中,但是
Exception in thread "main" org.eclipse.swt.SWTError: No more handles (java.lang.UnsatisfiedLinkError: Could not load SWT library. Reasons: 
no swt-xulrunner-win32-3740 in java.library.path
no swt-xulrunner-win32 in java.library.path
Can't load library: C:\Users\Administrator\.swt\lib\win32\x86_64\swt-xulrunner-win32-3740.dll
Can't load library: C:\Users\Administrator\.swt\lib\win32\x86_64\swt-xulrunner-win32.dll
)
at org.eclipse.swt.SWT.error(SWT.java:4308)
at org.eclipse.swt.SWT.error(SWT.java:4197)
at org.eclipse.swt.browser.Mozilla.initXULRunner(Mozilla.java:2458)
at org.eclipse.swt.browser.Mozilla.create(Mozilla.java:672)
at org.eclipse.swt.browser.Browser.<init>(Browser.java:99)
at com.fenbeisoft.user.BrowserTest1.main(BrowserTest1.java:31)
Caused by: java.lang.UnsatisfiedLinkError: Could not load SWT library. Reasons: 
no swt-xulrunner-win32-3740 in java.library.path
no swt-xulrunner-win32 in java.library.path
Can't load library: C:\Users\Administrator\.swt\lib\win32\x86_64\swt-xulrunner-win32-3740.dll
Can't load library: C:\Users\Administrator\.swt\lib\win32\x86_64\swt-xulrunner-win32.dll
at org.eclipse.swt.internal.Library.loadLibrary(Library.java:285)
at org.eclipse.swt.internal.Library.loadLibrary(Library.java:194)
at org.eclipse.swt.browser.Mozilla.initXULRunner(Mozilla.java:2456)
... 3 more

有哪些东西需要安装的或者有其他的要求,请告知下,谢谢!
shell FireFox eclipse xulrunner swt

------解决方案--------------------
64位就下xulrunner-1.8.1.2pre.en-US.win64之类的,要匹配