问题描述
我用netbeans开发了一个Java应用程序.它使用的是jdk 1.6.
I developed a java application with netbeans. It used jdk 1.6.
它工作正常.
但是现在的要求是,我需要在没有netbeans且使用jdk 1.5的另一台计算机上,从.java文件构建应用程序的jar.我无法将该计算机升级到jdk 1.6.
But now the requirement is I need to build the jar for the application from the .java files in another machine without netbeans and where jdk 1.5 is used. I cannot upgrade that machine to jdk 1.6.
有什么方法可以使我的java文件在jdk 1.5机器上编译和工作,而对我的源代码的更改可能最少.
Is there any way I could make my java files compile and work in jdk 1.5 machine with a possible minimal change to my source code..
错误是javax.swing.grouplayout在jdk 1.5中不可用
The error is javax.swing.grouplayout not available in jdk 1.5
请帮助...
推荐答案
使用netbeans首选项并选择org.jdesktop ....,通过右键单击表单(检查器窗口->选择swing,手动更新生成的代码)布局扩展而不是标准的Java6代码).
Use the netbeans preferences and select org.jdesktop...., update manually the generated code by right-click in the form (Inspector Window -> select swing layout extensions instead of standard java6 code).
这篇关于JDK 1.5中不存在javax.swing.grouplayout的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!