如何在netbeans项目中导入zip文件 [英] How to import zip file in netbeans project

查看:657
本文介绍了如何在netbeans项目中导入zip文件的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

当我尝试在我的netbeans项目中导入一个zip文件时,我在这行中收到错误

import jericho-html-3.1.src.java.net.htmlparser .jericho。*;

when I was trying import a zip file in my netbeans project, I get a error in this line
import jericho-html-3.1.src.java.net.htmlparser.jericho.*;

即使我添加了zip文件Libraries文件夹。

even though I added the zip file Libraries folder.

推荐答案

您可能希望将库添加到项目中,以便在代码中调用它。
从行导入jericho-html-3.1.src.java.net.htmlparser.jericho。*; 我假设您尝试将源代码添加到项目。这不起作用。

You probably want to add library to your project so you could call it in your code. From the line import jericho-html-3.1.src.java.net.htmlparser.jericho.*; I assume that you try to add source code to the project. This will not work.

您需要添加库库而不是源代码。库文件具有 .jar 扩展名。
http://sourceforge.net下载zip文件时/projects/jerichohtml/files/jericho-html/3.1/ 该库位于 /jericho-html-3.1/dist / zip文件夹中。

You need to add a library library and not source code. The library file has .jar extension. When you download a zip file from http://sourceforge.net/projects/jerichohtml/files/jericho-html/3.1/ The library is in /jericho-html-3.1/dist/ folder of the zip.

有关图书馆的使用,请查看示例程序

For library usage take a look on Sample Programs.

这篇关于如何在netbeans项目中导入zip文件的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆