3

我使用 Netbeans 创建了一个 GUI 应用程序,它与数据库(localhost)有一个连接。

现在我希望能够将它作为软件分发。

有没有办法为 Netbeans 项目生成安装文件?以及如何分发使用 MySQL 数据库的 Netbeans 项目?

4

3 回答 3

3

how can I distribute a Netbeans project which uses a MySQL database?

You might want to get familiar with NSIS. NSIS will enable you to automate the installation process.

Your installation process will have to do the following:

  • Check that the Java Runtime Environment is the same version you used or higher.
  • Install your application JAR file somewhere.
  • Install the MySQL version that your application requires
  • Create and initialize the tables for your application.

Your installation process can do the following:

  • Create an uninstall executable.
  • Add an icon so that the user can start your application.

This installation process will take some time to develop and test.

于 2012-09-14T16:21:39.807 回答
2

您可能想要使用安装程序。看一下:

还有很多其他的,但我希望这可以帮助你......

于 2012-09-14T19:28:56.127 回答
0

Use the solution made by the suppliers of Java - Java Web Start.

  • The deployJava.js (described in the linked page) ensures the user has the minimum JRE needed to launch the app. & MySQL.
  • Launch the app. using Java Web Start.
    • Reference an installer-desc extension for installing the DB. Store any set-up details into the PersistenceService for later use.

JWS works on all major platforms for which J2SE is available and also provides..

..many appealing features including, but not limited to, splash screens, desktop integration, file associations, automatic update (including lazy downloads and programmatic control of updates), partitioning of natives & other resource downloads by platform, architecture or Java version, configuration of run-time environment (minimum J2SE version, run-time options, RAM etc.), easy management of common resources using extensions..

于 2012-09-14T23:12:11.867 回答