Java Forums

Main Menu
Home
Today's Posts
FAQ
Search
Contact Us

Java Network
Linux Archive
Java Tips
Java Tips Blog

Sponsored Links





Welcome to the Java Forums.

You are currently viewing our boards as a guest which gives you limited access to view most discussions and access our other features. By joining our free community, you will:

  • have access to post topics
  • communicate privately with other members (PM)
  • not see advertisements between posts
  • have the possibility to earn one of our surprises if you are an active member
  • access many other special features that will be introduced later.

Registration is fast, simple and absolutely free so please, join our community today!

If you have any problems with the registration process or your account login, please contact us.

Reply
 
LinkBack Thread Tools Display Modes
  #1 (permalink)  
Old 05-20-2007, 10:40 PM
Member
 
Join Date: May 2007
Posts: 10
Valeriano is on a distinguished road
How to convert a String to upper case
I am getting a string from the user and i need to convert it to upper case. How can i do this?
Bookmark Post in Technorati
Reply With Quote
Sponsored Links
  #2 (permalink)  
Old 05-20-2007, 10:43 PM
Senior Member
 
Join Date: Dec 2006
Posts: 748
levent is on a distinguished road
Hi Valeriano,

You can use toUpperCase() method of String class. String class has lots of more useful methods.
Bookmark Post in Technorati
Reply With Quote
  #3 (permalink)  
Old 06-28-2007, 07:45 AM
Member
 
Join Date: Jun 2007
Posts: 3
amateur83 is on a distinguished road
String s1 = "test";

s1 = s1.toUpperCase();

System.out.println(""=========RESULT=========" + s1);

//it'll print TEST
Bookmark Post in Technorati
Reply With Quote
Sponsored Links
Reply


Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
String manipulation example (Title case) Java Tip Java Tips 0 01-29-2008 11:04 AM
String Title case bugger New To Java 4 01-28-2008 07:06 PM
convert string to a double? javaMike Advanced Java 2 11-27-2007 05:10 AM
convert string to float miss_dot NetBeans 1 11-15-2007 01:26 AM
How to convert a string into a BigInteger valery New To Java 1 08-06-2007 10:36 PM


All times are GMT +3. The time now is 10:10 PM.


VBulletin, Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
Content Relevant URLs by vBSEO ©2007, Crawlability, Inc.
Copyright ©2006 - 2007, www.java-forums.org