|Re: Trying to Import existing Java code into an Eclipse project [message #871210 is a reply to message #870545]
||Fri, 11 May 2012 13:03
| Russell Bateman
Registered: July 2009
Location: Provo, Utah, USA
On 05/08/2012 09:53 AM, Rick Dabate wrote:|
> I'm, as new as they come. Going through a Java book for beginners.
> Now, I'm at a step where it tells me to try to import the test code. I
> go through the wizard , but do not see the Test.java anywhere within
> Eclipse. However, if I browse to my work space and open the Test
> Projects folder, I see the Test.Java that was imported.
> Shouldn't I be able to see the Test.Java within Eclipse somewhere?
You don't say what you've done here to import the project.
You can only import actual Eclipse projects. These are characterized by
..project, .classpath, and maybe other files in the project root. If this
is not the case, then you must create a new project that uses your code.
There are different kinds of projects offered by Eclipse, but the
simplest one is the Java Project. To create a new project of this source
code you wish to use assumes that it's already in a reasonable
subdirectory hierarchy. I'll let you work that out for yourself, but you
might create a new, sample project in Eclipse to see how it builds the
When you create the new project for your existing code, the second step
in the project creation wizard/dialog is to point it to the root
subdirectory of that code. Make sure you do that.
After that, you'll need to add any supporting JARs to the project.
I suggest a tutorial on creating new Eclipse projects to familiarize you
with the Eclipse IDE. Drop anchor over at vogella.de and check out the
best ones available.
Best of luck.
Powered by FUDForum
. Page generated in 0.01657 seconds