i am a student and i desperately need to program java on my mac
now i am not gettint the "print text encoding" option as u do when u are saving the file , instead i get a "file format" option which is not allowing me to use java
I copied your diamond file on TextEdit but when i try to save it, it only allows me to save it as a .rtf when i try to change the extension to .java. PLEASE HELP
The osx operating system compiles just like any other program. You don't need any extra flags for a simple program like this. javac hello.java will still work. Thanks for posting the vid.
@beingRaghu hmmm...i really havent looked into using mac terminal for java applets....u can try this program called Blue J for mac...its a very simple and useful compiler and im very sure it can compile and run applets...
For the record, you can get away with compiling and running java without adding -classpath to javac. Also, I'm not sure why he's running the plain java command afterwards. After you compile, with javac diamond.java, immediately go into java diamond. Seems like he's taking some unnecessary steps for whatever reason
What does it mean by when someone say RUN this in a terminal?? Someone told me to run the following: sudo dscacheutil -flushcache to flush my cache. What does that mean and how do i do it?
@inditech96 no dont worry java is universal and the code doesn't change. Yes your right (String args[]) is used but it is not really required when using such a compiler :D
Javac -classpath . Welcome1.Java,odt is wat i typed in and thats my ezact file name and i was in the folder it was saved in and i got
error: Class names, 'Welcome1.Java.odt', are only accepted if annotation processing is explicitly requested
1 error
andi i did use open office as a text document and im positive i scripted it right it was taught in a class... so if u could please help it would be much appreciated
Well, here wat you can do, first update your java environment (jdk1.5 i think).... Next are you sure you are compiling it into a class file? your meant to compile it to a class file and then run the class file not the java file.... If nothing works tell me again... otherwise as i've mentioned before blue j is probably the best option and best compiler you can find u should download it :D just google it :D hope this help s:D
Instantly favorited! This video may have had problems with sound and clarity, but you described what to do and how to do it, that is what I like to see in a tutorial, and I can't understand why this video does not have WAY more views. I have been looking for a place to compile java for a long time. THANK YOU!!
thank you.. i appreciate your appreciation lolz... well my suggestion wouldbe that u get blue j cause its probablythe best compiler for java there is. You can find it in sun microsystem's website, they are the ones who introduced java lolz... thank you...
well actually it depends do u have a mac or a pc? i can easily tell u for both just tell me which part u didnt understand, im sure if u follow the ideo u should but if no tell me :D
@ratulcool1
hey..please help me
i am a student and i desperately need to program java on my mac
now i am not gettint the "print text encoding" option as u do when u are saving the file , instead i get a "file format" option which is not allowing me to use java
PLEASE HELP !!!
94vishu24 1 day ago
Do I have to install a software on my Mac to work with Java programming? or it's already installed with my Mac?
I wanna make sure, thanks
nawaryoussef1 2 weeks ago
I copied your diamond file on TextEdit but when i try to save it, it only allows me to save it as a .rtf when i try to change the extension to .java. PLEASE HELP
Thefuzzyman83 1 month ago
@Thefuzzyman83 when you save select plain text from the drop down menu at the bottom of the pane that appears, then change the .txt to .java
jam35ism 1 month ago
@Thefuzzyman83 same problem here
94vishu24 1 day ago
thanks for the help!
yeunghunlee 1 month ago
easy on the Enter key.. hehe!
d06murd 2 months ago
many thanks to you.
smoshfan10 2 months ago
The osx operating system compiles just like any other program. You don't need any extra flags for a simple program like this. javac hello.java will still work. Thanks for posting the vid.
lastnightsdinner 3 months ago
Thank you so much! Other videos didn't help at all /: this certainly did, and it was exactly what i was looking for(:
IsaiasTheMessiah 3 months ago
This has been flagged as spam show
how i can install javac in mac ??? can you help me
my email is : ahmad.badawood@gmail.com
AHMADBADAWOOD 3 months ago
whats cd? my .java is not on my pics folder... and copying the path doesnt work?
what if i have various layers?
Theboxset 4 months ago
Thank you :)
ThorTheScienceGuy 4 months ago
textedit will not allow me to save my program as .java
BellaCullen000 4 months ago
Hey all my java work is on my flash drive how do I access that in terminal
Ootini4 5 months ago
Comment removed
misterAdams2 9 months ago
if i want to make an extra folder inside 'Documents' called 'Java'.
and i want to store all my programs inside that 'java' folder' only.
then how do we define the path in terminal?
beingRaghu 11 months ago 2
@beingRaghu no probs just follow this command line:
cd Documents
cd Java
then access ur file
ratulcool1 11 months ago
@ratulcool1 thanks.!! it worked.
one more thing.. i tried basic java programs and they worked fine but...
How do i compile java Applets programs on mac..
i just added labels . and performed no action on them..but still the program does not compile.
beingRaghu 11 months ago
@ratulcool1 k thanks.. it worked fine.but when i wrote the java applet code.
ran it on terminal as u said.but still the msg appears saying "Exception in thread "main" java.lang.NoSuchMethodError:main"
.. ???
do i need to install any additional softwares or something to run AWT applets on mac??
beingRaghu 11 months ago
@beingRaghu hmmm...i really havent looked into using mac terminal for java applets....u can try this program called Blue J for mac...its a very simple and useful compiler and im very sure it can compile and run applets...
ratulcool1 11 months ago
Thank you so much! Saved my butt!
9Coronas 11 months ago
For the record, you can get away with compiling and running java without adding -classpath to javac. Also, I'm not sure why he's running the plain java command afterwards. After you compile, with javac diamond.java, immediately go into java diamond. Seems like he's taking some unnecessary steps for whatever reason
InternetGrind 1 year ago
This was the first concise answer I came across to my question. Thank you! You rock!
samuelbhatch 1 year ago
What compiler do you use for Classic Eclipse 3.6.1 for Java on Mac Snow Leopard besides Terminal?
neji064hyuga 1 year ago
What does it mean by when someone say RUN this in a terminal?? Someone told me to run the following: sudo dscacheutil -flushcache to flush my cache. What does that mean and how do i do it?
2233Brenda 1 year ago
it wont let me save it as java :s
fogbound007 1 year ago
Thanks, This was helpful
CrittyWitty 1 year ago
is the code different from that of windows? cuz the PSVM (main definition) ends with (string args[]) , I am a beginner, so tell me if I am wrong
inditech96 1 year ago
@inditech96 no dont worry java is universal and the code doesn't change. Yes your right (String args[]) is used but it is not really required when using such a compiler :D
ratulcool1 1 year ago
Javac -classpath . Welcome1.Java,odt is wat i typed in and thats my ezact file name and i was in the folder it was saved in and i got
error: Class names, 'Welcome1.Java.odt', are only accepted if annotation processing is explicitly requested
1 error
andi i did use open office as a text document and im positive i scripted it right it was taught in a class... so if u could please help it would be much appreciated
vint44 1 year ago
@vint44 ok well Ill help u out...
-firstly mail me or send me the source code so I can check it
-secondly, get blue J it has a really good debugger that is very useful
ratulcool1 1 year ago
Thanks alot bro really helped me out
armorcladmonkey 1 year ago
It worked perfectly!!! thank you so much. I really needed to learn this.
Daneish003 1 year ago
Hi
I hope you can help me with this
I have a program called CarFuel.java
so i did as you said
Javac -classpath . CarFuel.java
and then java
the java CarFuel
its says at java .security.lang
what is wrong
yamahaqi 2 years ago
first I need to know a few things...
-Are u the admin on it?
-Have u tried to run any other program?
-do u have jdk installed?
I will be able to help you if you could plz tell me these.
Also as I have repeatedly said, use bluej or eclipse they are amazing compilers and save much more time
ratulcool1 2 years ago
Every time I use the System.out.printIn method Terminal
tells me it can't find the symbol
need help!
BobG132 2 years ago
2 things-
-Are you sure your java environment is the latest version? jdk 6
-And second does that mean that System.out.print instead of System.out.println is working? Also, the syntax is System.out.println(" ");
ratulcool1 2 years ago
Please speak English, not that internet lingo. As well, I tried to load a "Hello World" program and Terminal resulted in
error: cannot read: helloworld.java
1 error
and
Exception in thread "main" java.lang.NoClassDefFoundError: helloworld
please help.
IG88isevil 2 years ago
Well, here wat you can do, first update your java environment (jdk1.5 i think).... Next are you sure you are compiling it into a class file? your meant to compile it to a class file and then run the class file not the java file.... If nothing works tell me again... otherwise as i've mentioned before blue j is probably the best option and best compiler you can find u should download it :D just google it :D hope this help s:D
ratulcool1 2 years ago
Instantly favorited! This video may have had problems with sound and clarity, but you described what to do and how to do it, that is what I like to see in a tutorial, and I can't understand why this video does not have WAY more views. I have been looking for a place to compile java for a long time. THANK YOU!!
IG88isevil 2 years ago
thank you.. i appreciate your appreciation lolz... well my suggestion wouldbe that u get blue j cause its probablythe best compiler for java there is. You can find it in sun microsystem's website, they are the ones who introduced java lolz... thank you...
ratulcool1 2 years ago
dude how do ucompile i dont know how please reply
zammey0wnz 2 years ago
well actually it depends do u have a mac or a pc? i can easily tell u for both just tell me which part u didnt understand, im sure if u follow the ideo u should but if no tell me :D
ratulcool1 2 years ago