hey i am making i own server atm but i cant compile. i have downloaded java and jdk but it still doesnt work. i know i have to set a path or something but im really new at this coding stuff and have no idea hwo to do this and without my compiler i cant update so its really driving me crazy.
Change "u" to "you" in title. CR[/edit] [ July 14, 2008: Message edited by: Campbell Ritchie ]
That isn't a compiler error; it is failure to find the compiler in the first place and is a very common problem. I wrote about it recently here; find that thread and follow the instructions and links there.
Joined: Oct 13, 2005
Please don't use abbreviations like "u" for "you;" I shall alter it. This FAQ explains why.
Joined: Jul 13, 2008
the guide on that link for updating the path varible is for windows xp and 2000 but im using windows vista and i cant find environment varibles on my computer
On Windows Vista: Click the Start button, right-click on Computer, select Properties. Then click Advanced System Settings on the left side of the window. Then you'll get the same settings window as on Windows XP; click the Environment Variables button.
(Note, my Windows Vista is in Dutch, and I'm guessing what the English names are).
The warning means what it says: You are using a API, or resource, (class/interface etc) that is marked as 'old', or deprecated. This doesn't mean that it won't work, just that it is not the recommended way any more. The suggestion of compiling with Xlint is good, you do it like this:
Now javac will tell you more about which API it considers old. Mostly (if not always?), the java specification documents (http://java.sun.com/reference/api/index.html) will give hints on what you should use instead of the old way. Hope this helps.
(Gah, stupid smilies... ) [ July 14, 2008: Message edited by: Carl Pettersson ]
brian layton wrote:i think i made a path for java now but my compiler still doesnt work it says ...
Note: stream.java uses or overrides a deprecated API.
Note: Recompile with -Xlint:Deprecation for details.
what do i do??
Same error for me. But can you all please tell us how to fix it?
Joined: Oct 13, 2005
Welcome to the Ranch
That is a completely different and unrelated problem from "cannot recognize javac . . .". It is not actually a compiler error, and your code will have been compiled. Do exactly what the message says
javac -Xlint:depreciation MyClass.java
That will give you a list of warnings of what you have used. When you find out which deprecated methods you have used, go to the link which Carl Pettersson quoted last year, then go to the methods or classes which your error message mentions, and it should tell you what to use instead. I have probably spelt depreciation wrongly; you may need to write Depreciation instead.