This week's book giveaway is in the Java in General forum.
We're giving away four copies of Event Streams in Action and have Alexander Dean & Valentin Crettaz on-line!
See this thread for details.
Win a copy of Event Streams in Action this week in the Java in General forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Devaka Cooray
  • Liutauras Vilda
  • Jeanne Boyarsky
  • Bear Bibeault
Sheriffs:
  • Paul Clapham
  • Knute Snortum
  • Rob Spoor
Saloon Keepers:
  • Tim Moores
  • Ron McLeod
  • Piet Souris
  • Stephan van Hulst
  • Carey Brown
Bartenders:
  • Tim Holloway
  • Frits Walraven
  • Ganesh Patekar

how to run

 
Greenhorn
Posts: 6
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
i have installed java in c: program files and trying to run it from java directory
with javac Helloworld.java but it is not working
i get the message that javac file cannot be recognized

Kindly help me urgentlyyyyyyyyyy
 
Ranch Hand
Posts: 580
Eclipse IDE
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Where is the *.java file stored??
From which dir you are exectuing the command.
 
lowercase baba
Posts: 12753
51
Chrome Java Linux
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
where is the javac.exe file saved, and is that directory in your PATH?
 
Marshal
Posts: 65062
247
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
So many people have that sort of problem that there is a section about it in the Java Tutorials. See whether that helps. Note there is a "common problems" page.
 
Ranch Hand
Posts: 30
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Set the path and classpath of the java directory as shown below.

1. Right Click My Computer and select properties.
2. click on Advanced tab and then click on Environmental variables button
3. click on New button of the system variables section and type the variable path as 'path' and variable value as 'java installed directory' + bin
(For eg: C:\Program Files\Java\jdk1.6.0_05\bin)
2009-01-06_212306.png
[Thumbnail for 2009-01-06_212306.png]
 
Campbell Ritchie
Marshal
Posts: 65062
247
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator

Kumaresh Vidhyasagar wrote:Set the path and classpath of the java directory as shown below.

A useful piece of information there, complete with screenshot, but only set the PATH. Don't do anything with CLASSPATH at this stage.
 
It is sorta covered in the JavaRanch Style Guide.
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!