日期:2014-05-20  浏览次数:20607 次

运行浏览器小程序时,出现:Cannot run program "IeEmbed.exe":错误,
最近想做一个浏览器,自己写了一个测试的小代码(如下),在网上找了配置方法后,如下是我导入的相关文件,可总出现:
isDefaultBrowserMozilla
isDefaultBrowserMozilla
Can't execute the native embedded browser. Error message: Cannot run program "IeEmbed.exe": CreateProcess error=2, ??Õ?»µ½?¶

import org.jdesktop.jdic.browser.*;
import java.net.*;
import javax.swing.*;

public class BrowserTest {
public static void main(String[] args) throws Exception {
WebBrowser browser = new WebBrowser();
browser.setURL(new URL("http://www.baidu.com"));
JFrame frame = new JFrame("Browser Test");
frame.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
frame.getContentPane().add(browser);
frame.pack();
frame.setSize(500, 500);
frame.setVisible(true);
System.out.println(browser.getURL());
}
}



各位大虾帮帮忙,先谢谢了


------解决方案--------------------
eclipse配置的问题

http://www.javaeye.com/topic/235154