Java - Ayuda... no me funciona java....

 
Vista:

Ayuda... no me funciona java....

Publicado por Claudia (2 intervenciones) el 16/03/2005 02:42:55
Hola, kisiera saber si alguien me puede ayudar a ver ke me falta agregar al classpath o al path para ke no me aparezca el error: exception in thread "main" java.lang.NoClassDefFoundError:

y se supone que tengo ya todas las rutas en classpath y en el path.
se los pongo:
Classpath=C:\JDBCTest1_03\classes;C:\Sun\AppServer\jdk1.4\lib;C:\tomcat\lib;C:\tomcat\common\lib;
C:\mysql-connector-java-3.0.7-stable\mysql-connector-java-3.0.7-stable-bin;C:\Sun\AppServer\jdk1.4\jre

Path=%SystemRoot%\system32;%SystemRoot%;%SystemRoot%\System32\Wbem;C:\mysql\bin;
C:\Sun\AppServer\jdk1.4\bin;TOMCAT_HOME\bin;C:\Sun\AppServer\jdk1.4

java_home=C:\Sun\AppServer\jdk1.4

Por fa!! .... ayudame si?
Gracias.
Valora esta pregunta
Me gusta: Está pregunta es útil y esta claraNo me gusta: Está pregunta no esta clara o no es útil
0
Responder

RE:Ayuda... no me funciona java....

Publicado por sergey (2 intervenciones) el 16/03/2005 17:09:17
set TOMCAT_HOME = C:\YourToMCatDir!;

Path=%SystemRoot%\system32;
%SystemRoot%;%SystemRoot%\System32\Wbem;
C:\mysql\bin;
C:\Sun\AppServer\jdk1.4\bin;
%TOMCAT_HOME%\bin;
C:\Sun\AppServer\jdk1.4;
C:\Sun\AppServer\jdk1.4\bin\

set CLASSPATH=.;
C:\JDBCTest1_03\classes;
C:\Sun\AppServer\jdk1.4\lib;
C:\tomcat\lib;
C:\tomcat\common\lib;
C:\mysql-connector-java-3.0.7-stable\mysql-connector-java-3.0.7-stable-bin;
C:\Sun\AppServer\jdk1.4\jre

set JAVA_HOME=C:\Sun\AppServer\jdk1.4

Usualy compiled java classes (*.class) packed in JAR files. java.exe, javac.exe will search for *.class files in
Directory's in your classpath, but will NOT search for *.class files packed in JAR (in your classpath only directorys).

You using mySQL JDBC drivers???
U must add mySQL driver in C:\Sun\AppServer\jdk1.4\bin\jre\lib\ext (Add all *.jar files that U need in this dir (your current JAVA_HOME))
OR edit your classpath in this way (add evry JAR file that U need):
C:\mysql-connector-java-3.0.7-stable\mysql-connector-java-3.0.7-stable-bin\yourConnectorDriver.JAR;

My autoexec.bat file:
path=c:;c:\dos\boot;c:\Program Files\java\jdk1.5.0\bin
set CLOUDSCAPE_INSTALL=C:\Program Files\IBM\Cloudscape_10.0
set CLASSPATH=.;%CLOUDSCAPE_INSTALL%\lib\derby.jar; %CLOUDSCAPE_INSTALL%\lib\derbytools.jar

Plz read:
http://onesearch.sun.com/search/developers/index.jsp?charset=UTF-8&qt=classpath&col=javadoc&col=javatecharticles&col=javatutorials&col=devarchive&col=javasc&col=devall

use free Java IDE:
www.eclipse.org
www.netbeans.org
Valora esta respuesta
Me gusta: Está respuesta es útil y esta claraNo me gusta: Está respuesta no esta clara o no es útil
0
Comentar