Hi all tht u can do to set classpath is
1) open dos ther type
set classpath=c\doc...\lib;
or
right click on ,y computer go to propertis,
click on Environment variables, click new put name of variable as classpath
value as : c\doc..\lib;
still u have issues let me know
With Windows, on the command prompt, you can add to the classpath by saying,
set CLASSPATH=%CLASSPATH%; C:\Documents and Settings\india;
But this will only work for that one window.
To set it for the system, modify Environment Variables under System Properties > Advanced reached by right-clicking My Computer and selecting Properties.
If there isn't already a variable called CLASSPATH, add it. And as it's value, add the path to the directory where your classes will be.
I usually add '.' ( current directory ) as
set CLASSPATH= %CLASSPATH% .;
while i'm testing out my code.
An alternative - as stated in reply 2 in your other thread on this topic: http://forum.java.sun.com/thread.jspa?threadID=5170470 - is not to set the CLASSPATH environment variable at all. Use the -classpath switch instead.
As the documentation linked to in that reply points out: "The class search path (more commonly known by the shorter name, "class path") can be set using either the -classpath option when calling a JDK tool (the preferred method) or by setting the CLASSPATH environment variable. The -classpath option is preferred because you can set it individually for each application without affecting other applications and without other applications modifying its value."
As always, the documentation is worth reading; the available command line options worth using.