Re: cant's compile with javac
- From: Noodles Jefferson <silverbells@xxxxxxxxxxxxxx>
- Date: Sun, 27 Nov 2005 19:40:06 -0600
In article <1133129500.547883.85290@xxxxxxxxxxxxxxxxxxxxxxxxxxxx>,
Ido.Yehieli@xxxxxxxxx took the hamburger, threw it on the grill, and I
said "Oh wow"...
> it just says:
> Exception in thread "main" java.lang.NoClassDefFoundError:
> com/sun/tools/javac/Main
>
> when I dod that.
>
>
NoClassDefFoundError means that whatever you're looking to compile can't
be found by the compiler. You can compile something by being in the same
directory as where your source file is or you can use a path with javac
which tells it to look for your source file, then compile it.
(I think there's more ways than just that to compile but I'll leave that
to the hotshots of the group to expound on.)
Compile from the same directory as your source:
open a command prompt.
c:\stuff\morestuff> -- where you're at right now. I'm sure you know this
already.
K: -- navigate to the K: drive (I usually do this from the top directory
on the drive; for example, C:> but others may do that differently)
cd.. -- move up one folder
cd directoryName -- move to the directory (which would be directoryName)
dir -- show everything in the folder you're in
cd directoryName\anotherDirectory -- Move to the directoryName folder
then go anotherDirectory within that.
Once you're there, javac YourFile.java
javac using a path:
javac just\tell\thecompiler\where\it\can\find\your\file\YourFile.java
If the file's on another drive, I'll navigate to the drive and then
start my path. That's just what I do though. Others may have a
different/better way.
If Eclipse can find it, you can find it because it can't compile stuff
out of thin air. It has to find a source somewhere.
--
Noodles Jefferson
mhm31x9 Smeeter#29 WSD#30
sTaRShInE_mOOnBeAm aT HoTmAil dOt CoM
"Our earth is degenerate in these latter days, bribery and corruption
are common, children no longer obey their parents and the end of the
world is evidently approaching."
--Assyrian clay tablet 2800 B.C.
.
- Follow-Ups:
- Re: cant's compile with javac
- From: Roedy Green
- Re: cant's compile with javac
- References:
- cant's compile with javac
- From: Ido . Yehieli
- Re: cant's compile with javac
- From: Noodles Jefferson
- Re: cant's compile with javac
- From: Ido . Yehieli
- cant's compile with javac
- Prev by Date: Re: cant's compile with javac
- Next by Date: Re: cant's compile with javac
- Previous by thread: Re: cant's compile with javac
- Next by thread: Re: cant's compile with javac
- Index(es):
Relevant Pages
|