• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 209
  • Last Modified:

Java compilation problem

Hi, experts

I am using win2k advance server. I have set the classpath for java. But when I compile java file in some folders, there are many errors. I have to go to Control panel - system - advanced - environment variables, then click OK. It would be ok to compile the java files.

Could you please help me to fix it? thanks.
0
jl2001
Asked:
jl2001
1 Solution
 
maggariCommented:
Make sure that all the class files that you use in your java programs are in the classpath ( not just jdk jars). Also, one common mistake we do is, we forget to keep the current folder in classpath. Make sure classpath variable starts something like this:

Classpath=.;

0
 
asharma2Commented:
You should put your working directory (i.e. where you java files are) in the class path.Before compilatiotn.
set classpath=%classpath%;. will do .


0

Featured Post

Free Tool: IP Lookup

Get more info about an IP address or domain name, such as organization, abuse contacts and geolocation.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Tackle projects and never again get stuck behind a technical roadblock.
Join Now