我一直在试图在NetBeans上运行一个简单的程序,但是刚打开RUN时,我收到一个消息框 - 一个或多个项目编译时出现错误。应用程序可能会结束不料。 当我“运行反正”我得到需要的结果的程序,但如果我取消它,我得到的输出此错误pane-编译有一个或多个错误的NetBeans项目
运行:/root/.netbeans/6.8/var/cache /executor-snippets/run.xml:45: 用户
当我点击了错误而被取消,我转到了
<translate-classpath classpath="${classpath}" targetProperty="classpath-translated" />
行上run.xml文件。
我的代码是:
public class minitest {
public static void main(String[] args) {
Connect conn=null;
try{
Domain testDomain=conn.domainLookupByName("test");
System.out.println("Domain:" + testDomain.getName() + " id " +
testDomain.getID() + " running "
);
} catch (LibvirtException e){
System.out.println("exception caught:"+e);
System.out.println(e.getError());
}
}
} }
谢谢!