在netbeans中创建/访问库 [英] Creating/accessing libraries in netbeans

查看:153
本文介绍了在netbeans中创建/访问库的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我是一名新的netbeans用户,我在导入用户创建的库时遇到问题。

I am a new netbeans user, and I'm having trouble importing user created libraries.

我创建了一个名为MyLibrary的库。然后我添加了一个文件夹,其中包含我保存的项目(名为netbeansProjects)到类路径,我在netbeans IDE中编写。现在我正在尝试将一个类导入到我正在处理的项目中,但它不允许我这样做。我正在按摩套餐不存在。我真的很感激这个问题的一些帮助。我在网上搜索;我找不到任何东西。

I created a library named "MyLibrary". I then added a folder that contains my saved projects (entitled "netbeansProjects") to the classpath, which I wrote in the netbeans IDE. Now I'm trying to import a class into a project I'm working on, but it wont allow to me to it. I'm getting the massage "Package does not exist". I would really appreciate some assistance on this problem. I searched online; I couldn't find anything.

推荐答案

您必须使用Netbeans Library Manager创建库。转到工具 - > 然后选择新库... 按钮并创建一个新的类库。您只能使用此方法而不是Netbeans项目添加jar文件。

You'll have to create the library using the Netbeans Library Manager. Go to Tools ->Libraries then select the New Library... button and make a new Class Library. You will only be able to add jar files using this method not a Netbeans project.

添加Netbeans项目:

To add a Netbeans project:

在Netbeans Projects窗口中右键单击项目下的 Libraries 文件夹,然后选择添加项目... 然后导航到您想要使用的Netbeans项目。
您必须为要使用的每个项目执行此操作。

In the Netbeans Projects window right click on Libraries folder under your project, and select Add Project... then navigate to the Netbeans project your would like use. You will have to do this for each project you would like to use.

这篇关于在netbeans中创建/访问库的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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