• 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 Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

javac

 
Greenhorn
Posts: 9
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hello, I do HelloWorld app, but when you compile the command line, I received a error.

error:cannot read: HelloWorldApp.java
1 error

Help me please!
Thanks in advance!
 
Bartender
Posts: 2236
63
IntelliJ IDE Firefox Browser Spring Java Linux
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
What OS are you using? It looks like you don't have reading permissions on that file.
 
Java Cowboy
Posts: 16084
88
Android Scala IntelliJ IDE Spring Java
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Is there a file named "HelloWorldApp.java" in your current directory?

Did you save it with Windows Notepad? It might have saved it as "HelloWorldApp.java.txt". Rename it to "HelloWorldApp.java".
 
Grigorii Malakhov
Greenhorn
Posts: 9
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
here's a screenshot of my screen!
-.gif
[Thumbnail for -.gif]
 
Grigorii Malakhov
Greenhorn
Posts: 9
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Jesper de Jong wrote:Is there a file named "HelloWorldApp.java" in your current directory?

Did you save it with Windows Notepad? It might have saved it as "HelloWorldApp.java.txt". Rename it to "HelloWorldApp.java".



I did everything as you said, but now he gives me another
-.gif
[Thumbnail for -.gif]
screenshot
 
Bartender
Posts: 11497
19
Android Google Web Toolkit Mac Eclipse IDE Ubuntu Java
  • Likes 1
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Java is case sensitive. Try javac HelloWorldApp.java (and not HelloWorldApp.JAVA)
Also, like Jesper said, make sure the HelloWorldApp.java is in your current directory.

In future, please do not post screenshots. You can always copy the console text and paste it here (Please UseCodeTags)
 
Grigorii Malakhov
Greenhorn
Posts: 9
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Maneesh Godbole wrote:Java is case sensitive. Try javac HelloWorldApp.java (and not HelloWorldApp.JAVA)
Also, like Jesper said, make sure the HelloWorldApp.java is in your current directory.

In future, please do not post screenshots. You can always copy the console text and paste it here (Please UseCodeTags)




Did all of the writing here is the error which he gave me!

C:\Users\ДИМА>javac HelloWorldApp.java
error: cannot read: HelloWorldApp.java
1 error
 
Rancher
Posts: 1044
6
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
What is the output for this command?

C:\Users\ДИМА>dir HelloWorldApp.java



 
Grigorii Malakhov
Greenhorn
Posts: 9
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Ivan Jozsef Balazs wrote:What is the output for this command?

C:\Users\ДИМА>dir HelloWorldApp.java




Here is what he wrote:


C:\Users\ДИМА> dir HelloWorldApp.java
Volume in drive C has no label.
Volume serial number: 1234-1234

The contents of a folder C:\Users\ДИМА

File not found
 
Paweł Baczyński
Bartender
Posts: 2236
63
IntelliJ IDE Firefox Browser Spring Java Linux
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
That means exactly what it sais:
There is no HelloWorldApp.java file in C:\Users\ДИМА directory.
Where did you save your file? Maybe it is named HelloWorldApp.java.txt.
Exacute
dir *.java
and then
dir HelloWorldApp*
and paste the results here.
 
Grigorii Malakhov
Greenhorn
Posts: 9
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Pawel Pawlowicz wrote:That means exactly what it sais:
There is no HelloWorldApp.java file in C:\Users\ДИМА directory.
Where did you save your file? Maybe it is named HelloWorldApp.java.txt.
Exacute
dir *.java
and then
dir HelloWorldApp*
and paste the results here.



Вот что он написал:

C:\Users\ДИМА>dir HelloWorldApp.java
Volume in drive C has no label.
Volume serial number: 1234-1234

The contents of a folder C:\Users\ДИМА

27.08.2013 19:05 259 HelloWorldApp.java
1 files 259 bytes
0 folders 81 547 264 bytes free
 
Ivan Jozsef Balazs
Rancher
Posts: 1044
6
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
First you reported this:


Here is what he wrote:
C:\Users\ДИМА> dir HelloWorldApp.java
Volume in drive C has no label.
Volume serial number: 1234-1234
The contents of a folder C:\Users\ДИМА
File not found



And later you reported that:


C:\Users\ДИМА>dir HelloWorldApp.java
Volume in drive C has no label.
Volume serial number: 1234-1234
The contents of a folder C:\Users\ДИМА
27.08.2013 19:05 259 HelloWorldApp.java
1 files 259 bytes
0 folders 81 547 264 bytes free



It is inconsistent. Maybe you created the file in the mean while, but then the previous compilation attempts lost their significance.
 
Ivan Jozsef Balazs
Rancher
Posts: 1044
6
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Let me recommend this reading:
Oracle tutorial

 
Grigorii Malakhov
Greenhorn
Posts: 9
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Thank You Very Much! It worked out!
 
Ivan Jozsef Balazs
Rancher
Posts: 1044
6
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
You're welcome.

Hа здоровье!
(I wanted to write something friendly in Russian, but my Russian is weak and seriously limited ...)
 
incandescent light gives off an efficient form of heat. You must be THIS smart to ride this ride. Tiny ad:
a bit of art, as a gift, that will fit in a stocking
https://gardener-gift.com
reply
    Bookmark Topic Watch Topic
  • New Topic