有 Java 编程相关的问题?

你可以在下面搜索框中键入要查询的问题!

java您的活动平台是:default\u platform,但找不到相应的属性“platforms.default\u platform.home”

我目前正在开发JavaFX应用程序。我以前使用过Netbeans 7.4,但现在我改用Netbeans 8.0.2。使用新IDE运行我的项目后,出现了一个错误,错误是:

C:\projects\client\QueueBoard\nbproject\build-impl.xml:87: The J2SE Platform is not correctly set up.
Your active platform is: default_platform, but the corresponding property "platforms.default_platform.home" is not found in the project's properties files. 
Either open the project in the IDE and setup the Platform with the same name or add it manually.
For example like this:
ant -Duser.properties.file=<path_to_property_file> jar (where you put the property "platforms.default_platform.home" in a .properties file)
or ant -Dplatforms.default_platform.home=<path_to_JDK_home> jar (where no properties file is used)
BUILD FAILED (total time: 0 seconds)

你如何解决这个问题


共 (1) 个答案

  1. # 1 楼答案

    解决此问题的最简单方法是:

    1. 在NetBeans中打开项目
    2. 打开此项目的项目设置
    3. 检查(可能纠正/修复)所有设置(包括平台设置)
    4. 在“设置”对话框中单击“保存/确定”
    5. 清洁+建造项目

    这样,项目设置文件将更新为当前设置

    干杯