wood burning stoves 2.0*
The moose likes Beginning Java and the fly likes Could anyone help with this??? Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


JavaRanch » Java Forums » Java » Beginning Java
Bookmark "Could anyone help with this???" Watch "Could anyone help with this???" New topic
Author

Could anyone help with this???

Anthony Vit
Greenhorn

Joined: Nov 27, 2004
Posts: 7
I need to uppercase my output and I have tried every which way and can't figure it out. Can anyone tell me how to do this??? I am desparate!!! thanks in advance.




Ernest Friedman-Hill
author and iconoclast
Marshal

Joined: Jul 08, 2003
Posts: 24187
    
  34

Did you look carefully at the Javadoc page for the java.lang.String class?


[Jess in Action][AskingGoodQuestions]
shandilya popuru
Ranch Hand

Joined: Dec 21, 2004
Posts: 95
hi tony

use this objname[i].toUpperCase() in print


bye


sandy
Anthony Vit
Greenhorn

Joined: Nov 27, 2004
Posts: 7
Hey Sandy. Thanks for the input, but please don't think I am an idiot, but I don't know how to implement that statement. I am lost.
Johannes de Jong
tumbleweed
Bartender

Joined: Jan 27, 2001
Posts: 5089
System.out.println(words[idx].toUpperCase());

Anthony words in this case was the object, so Sandilya gave you the answer.

Ernest gave enough of a hint for you to find the answer yourself. If you want to become a Java programmer you will have to learn use the javadocs to find the methods an object has.

It is our policy to help but not to spoon feed, I made an exception here for you because its x-mas.
Natesh Kurup
Greenhorn

Joined: Nov 23, 2004
Posts: 19
Hi,

You could replace the code in your class with the below statement



hope this helps

rgds

natesh
Anthony Vit
Greenhorn

Joined: Nov 27, 2004
Posts: 7
Thanks everyone for your help. I am not expecting people to spoonfeed me. I needed some help. I am new at this stuff and I have been staring at it for hours now. Sometimes the obvious is not that obvious. thanks again everyone for your help. It is MUCH APPRECIATED!!!
Nigel Browne
Ranch Hand

Joined: May 15, 2001
Posts: 673
Originally posted by Anthony Vit:
.... I have been staring at it for hours now. Sometimes the obvious is not that obvious...


Sometimes it is best to get away from your PC when you are stuck and do something completely different. It is strange how given a bit of a rest the brain can recover and spot the answer to a problem that for hours had seemed impossible.

 
GeeCON Prague 2014
 
subject: Could anyone help with this???