Results 1 to 7 of 7
- 03-26-2011, 11:07 AM #1
Senior Member
- Join Date
- Feb 2011
- Posts
- 107
- Rep Power
- 0
Move project from netbeans to Eclipse
Hie guys can I please have some help.
I have been working on an assignment using Netbeans. I have written all the relevant classes and also built the GUI in netbeans.
I need to move my project back to eclipse so that it can run as an eclipse project, all our projects are supposed to be in an eclipse project. I have already finished the project so I am uninterested in being able to view the GUI design in eclipse (which I know is not possible)
How do I go about moving the project.
Many thanks in advance for your help.
-
You probably can export it as a Jar and then import the Jar into Eclipse.
- 03-26-2011, 11:53 AM #3
Senior Member
- Join Date
- Feb 2011
- Posts
- 107
- Rep Power
- 0
Please do not be annoyed but I am a complete novice. How do I export a project as a Jar and how would I import that to eclipse. Again, many thanks for your time.
- 03-26-2011, 01:34 PM #4
Could you explain what you tried and what went wrong?
Eclipse has an import function under the file-menu. As import source you can choose an archive file (fubarable's suggestion), the file system, an existing project and many more.
(Warning if using existing project: it is not moved but left in its original location).
I've very good experiences with just using copy-paste: make a new project and copy the directorytree with the sourcefiles (.java) in your new project's src-directory.
If you do this with seperate files into existing packages you have to edit the package within the files by hand.
- 03-26-2011, 04:30 PM #5
Senior Member
- Join Date
- Feb 2011
- Posts
- 107
- Rep Power
- 0
@Jodokus
I did the copy and paste thing as you suggested. The program is running fine in eclipse but there is an warning that I am seeing in eclipse. What do these mean. When I was in netbeans I did not see these errors.
The pictures are attached

-
Those are warnings not errors. Since your classes extend swing classes that implement the Serializable interface, Java is warning you that you don't declare a proper long field that the Serializable interface expects. You can ignore these warnings since you are not trying to serialize your GUI objects. If you want to get rid of them, you can change a global setting in Eclipse to ignore this or you can place the @SuppressWarnings("serial") annotation just above your class signature.
Java Code:@SuppressWarnings("serial") public class ShoppingCardDisplay extends javax.swing.JFrame { //....Last edited by Fubarable; 03-26-2011 at 04:56 PM.
- 03-26-2011, 05:00 PM #7
- Join Date
- Sep 2008
- Location
- Voorschoten, the Netherlands
- Posts
- 11,405
- Blog Entries
- 7
- Rep Power
- 17
Eclipse can be rather picky when it comes to classes that extend another class that implements the Serializable interface: it wants the extending class to implement a long serial version UID (see its warning messages). You can simply ignore those messages or do what Eclipse told you to do. You can also switch off those warning messages: go to Window>Preferences>Java>Compiler>Error/Warnings and deselect the "Serializable Class without SerialVersionUID" warning message. Do whatever you think is best for you.
kind regards,
JosWhen people rob a bank they get a penalty; when banks rob people they get a bonus.
Similar Threads
-
First EJB Project in NetBeans
By enzom83 in forum Enterprise JavaBeans (EJB)Replies: 1Last Post: 02-08-2011, 10:15 AM -
Porting a Netbeans project with .form files to Eclipse
By nds in forum EclipseReplies: 0Last Post: 12-28-2010, 09:05 AM -
Using NetBeans To Develop Project
By indra00 in forum Java AppletsReplies: 5Last Post: 07-04-2010, 06:24 PM -
Publish project from NetBeans
By ichwar in forum NetBeansReplies: 5Last Post: 08-19-2009, 03:28 PM -
importing a netbeans project in Eclipse
By javanoob#1 in forum EclipseReplies: 0Last Post: 02-10-2009, 11:20 PM


LinkBack URL
About LinkBacks
Reply With Quote

Bookmarks