This week's giveaway is in the Android forum.
We're giving away four copies of Android Security Essentials Live Lessons and have Godfrey Nolan on-line!
See this thread for details.
The moose likes Web Component Certification (SCWCD/OCPJWCD) and the fly likes sip[mple problem any help appreciated Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Android Security Essentials Live Lessons this week in the Android forum!
JavaRanch » Java Forums » Certification » Web Component Certification (SCWCD/OCPJWCD)
Bookmark "sip[mple problem any help appreciated" Watch "sip[mple problem any help appreciated" New topic
Author

sip[mple problem any help appreciated

deepa nari
Greenhorn

Joined: Nov 05, 2002
Posts: 20
I have windows98 and my tomcat runs fine.
I have installed sdk in in c:/j2sdk1.4.1 and my tomcat in c:/tomcat4.1
My tomcat runs fine.
But problem in running a java file in MSDOS.
I created a folder called testing under c:
c:/testing and try to run a simple java file in it
Lets say test.java
public class test {
public static vod main(String[] args) {
System.out.println("hello");
}
}
when i try to compile using javac test.java in MSDOS
i get error as Bad command or file name
AJAY RANA
Ranch Hand

Joined: May 30, 2002
Posts: 75
use SET PATH to point to javac.exe in ur jdk folder or JDK of tomcat !
i.e. either u can use
set path=%path%c:/j2sdk1.4.1/bin;
or instead give path of jdk/bin for tomcat directory hierarchy.
(try setting this in environmemt variable to make it permanent).
Hope this helps !
Regards,
Ajay Rana
SCJP2,SCWCD
[ December 03, 2002: Message edited by: AJAY RANA ]
deepa nari
Greenhorn

Joined: Nov 05, 2002
Posts: 20
I did it in autoexec.bat but no use.
still the same error??
How do i set it to permanent??
Maha Annadurai
Ranch Hand

Joined: Oct 27, 2002
Posts: 87
At command prompt, type the following commands.
At the end check what 'SET' command displays. Also pl. check if it has PATH set to your jdk's bin dir.
cd \
autoexec.bat
set
Regards
Maha Anna
Don Bosco
Ranch Hand

Joined: Oct 31, 2002
Posts: 108
hi deepa,
even i'm facing the same problem. my tomcat is running fine. i couldn't compile the java classes. cannot resolve symbol error occurs for all the servlet api.
guys, any help is greatly appreciated.


SCJP 1.4<p>Wingardium Leviosa!!
Don Bosco
Ranch Hand

Joined: Oct 31, 2002
Posts: 108
Well these are my environment variables
CATALINA_HOME=c:\Program Files\Apache Group\Tomcat 4.1
CLASS_PATH=c:\Program Files\Apache Group\Tomcat 4.1\common\lib\servlet.jar
JAVA_HOME=c:\j2sdk1.4.1_01
PATH=c:\j2sdk1.4.1_01\bin
is there anything i need to set?
Brusk Baran
Ranch Hand

Joined: Nov 15, 2001
Posts: 132
Don
i guess it'll be(the 2nd environment variable) CLASSPATH insted of CLASS_PATH.
adieu,
c.
John Pritchard
Ranch Hand

Joined: Nov 15, 2002
Posts: 49
Do you guys have the j2ee.jar from the J2EE SDK in your class path? you'll need that for command line compiles with J2EE imports.


John Pritchard<br />If a JTree falls in the woods, is it Observable
 
Consider Paul's rocket mass heater.
 
subject: sip[mple problem any help appreciated
 
Similar Threads
File listing not working in Tomcat
package
Bad Class File?
String format to create directory in Unix
packing classpath errors