trouble with Ecplise

a lot of compiling errors

Unresolved compilation problems:

The constructor GroupLayout(JPanel) is undefined

The method setLayout(LayoutManager) in the type Container is not applicablefor the arguments (GroupLayout)

org.jdesktop.layout.GroupLayout.LEADING cannot be resolved

code is

org.jdesktop.layout.GroupLayout jPanel1Layout =new org.jdesktop.layout.GroupLayout(jPanel1);

jPanel1.setLayout(jPanel1Layout);

jPanel1Layout.setHorizontalGroup(

jPanel1Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)

.add(org.jdesktop.layout.GroupLayout.TRAILING,

jPanel1Layout.createSequentialGroup()

.add(jPanel1Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)

.add(jPanel1Layout.createSequentialGroup()

.add(23, 23, 23)

.add(jPanel1Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)

.add(jLabel2)

.add(jLabel3))

.add(28, 28, 28)

.add(jPanel1Layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)

.add(jTextField1,

org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, 145,

org.jdesktop.layout.GroupLayout.PREFERRED_SIZE)

.add(jPanel1Layout.createSequentialGroup()

.add(jTextField3,

org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, 82,

org.jdesktop.layout.GroupLayout.PREFERRED_SIZE)

.addPreferredGap(org.jdesktop.layout.LayoutStyle.RELATED)

[1530 byte] By [ardmorea] at [2007-10-3 11:39:46]
# 1

> a lot of compiling errors

> Unresolved compilation problems:

> The constructor GroupLayout(JPanel) is undefined

This is a very clear error. GroupLayout doesn't have a constructor that takes in a JPanel.

> The method setLayout(LayoutManager) in the type

> e Container is not applicable for the arguments (GroupLayout)

Another clear problem with parameters

> org.jdesktop.layout.GroupLayout.LEADING cannot be

> e resolved

GroupLayout doesn't have a LEADING variable.

These are simple problems that I think you can handle on your own. If I am missing something please clarify.

Also, your code looks like it was generated by something and is really ugly. If you are going to have to maintain this or modify it, I would suggest you clean it up and make it more readable.

Also, your title is misleading because this has nothing to do with Ecplise.

zadoka at 2007-7-15 14:08:48 > top of Java-index,Developer Tools,Java Compiler...
# 2
Thanks!But I am told that if netbean IDE is used, the issue will be resloved automatically since it contains the desktop package.Is this true?I am using Ecplise IDE.How to treat it?
ardmorea at 2007-7-15 14:08:48 > top of Java-index,Developer Tools,Java Compiler...
# 3

> Thanks!

> But I am told that if netbean IDE is used, the issue

> will be resloved

> automatically since it contains the desktop package.

>

> Is this true?

>

> I am using Ecplise IDE.

> How to treat it?

It doesn't matter what IDE you use or if you compile at the command line you need all the correct classes in your class path. If you are trying to use classes that you have not added to your classpath, then in Eclipse, Netbeans etc. you need to fix it.Also, I would suggest you not use an IDE until you get a better understanding of what you are doing.

zadoka at 2007-7-15 14:08:48 > top of Java-index,Developer Tools,Java Compiler...