Using an external package/class files [message #146994] |
Thu, 06 April 2006 14:18  |
Eclipse User |
|
|
|
Originally posted by: steveb.phoenixscripts.co.uk
I'm making a program for a University project and have been provided with
a 'black-box' that performs most of the functions the program will be
dealing with. The format of the black-box is some .class files in a folder
structure, in such a way that the location of the files from my main
directory is .\uk\ac\bath\CM10137. I then import the necessary classes
with
"import uk.ac.bath.CM10137.*;"
But eclipse is failing to recognize the classes in the folders. It will
underline all the classes from the blackbox in red, saying it cannot
resolve to a type, but the errors are not listed in the Problems panel.
The program will then run without issues (sometimes), but I get none of
the benefits of code insight/completion, which is why I used eclipse in
the first place.
What do I need to do to make eclipse understand the files properly?
Thanks,
Steve
|
|
|
|
Re: Using an external package/class files [message #147108 is a reply to message #146994] |
Thu, 06 April 2006 18:37  |
Eclipse User |
|
|
|
Originally posted by: eclipse3.rizzoweb.com
Steve wrote:
> I'm making a program for a University project and have been provided
> with a 'black-box' that performs most of the functions the program will
> be dealing with. The format of the black-box is some .class files in a
> folder structure, in such a way that the location of the files from my
> main directory is .\uk\ac\bath\CM10137. I then import the necessary
> classes with "import uk.ac.bath.CM10137.*;"
> But eclipse is failing to recognize the classes in the folders. It will
> underline all the classes from the blackbox in red, saying it cannot
> resolve to a type, but the errors are not listed in the Problems panel.
> The program will then run without issues (sometimes), but I get none of
> the benefits of code insight/completion, which is why I used eclipse in
> the first place.
>
> What do I need to do to make eclipse understand the files properly?
The files need to be added to the build path of your project (Right
click the project and choose Properties, then Add Class Folder... on the
Libraries tab).
Hope this helps,
Eric
|
|
|
Powered by
FUDForum. Page generated in 0.07665 seconds