When you start learning java, first thing you do install the java and set the classpath. Since the classpath has been set, at command prompt if you shoot java or javac command it will be presented with the command options irrespective of the path from where you are shooting, in fact this is the way you check wheather the classpath has been successfully set.
I remember during my college days, I faced the problem where I was not able to set the classpath. First I have installed the JDK and opened the command prompt, tried to run the java and javac command. Since the classpath has not been set, it was not recognized as a external or internal command. Now I have set the classpath and at the same command prompt, I tried to run java commands again the result was the same.
Was that the OS problem or something wrong with my declarations?
Any guesses? ?????????
The reason is simple when you open the command prompt, it takes account of the classpath and provides the memory to run the command. Now the catch is if you modify the classpath and do not open the new command window to run java command and try to run with the same old command window it considers the same old classpath again.
So everytime you modify the classpath, open the new command window is always the best possible option.
Few more tips on classpth....coming soon :))
With how to write the web service to transfer the files across any geographical location over the internet using server client mechanism....:))))))))))))))
Till then enjoy...................
ATUL PATEL
No comments:
Post a Comment