Java Help
 
Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
User Name:
Password:
Remember me
Go Back   Dev Shed ForumsProgramming LanguagesJava Help

Reply
Add This Thread To:
  Del.icio.us   Digg   Google   Spurl   Blink   Furl   Simpy   Y! MyWeb 
Thread Tools Search this Thread Rate Thread Display Modes
 
Unread Dev Shed Forums Sponsor:
Stop making mediocre tutorials.The best tutorials are video! Camtasia Studio makes it easy to create engaging, buzz-building screen videos at any size, in any popular format. Download the free trial!
  #1  
Old October 1st, 2002, 04:25 AM
peter83 peter83 is offline
Member
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Aug 2002
Posts: 19 peter83 User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 0
add alphabets to a string

i need to check if a name(string) is already in database and if it is in, i need to add alphabets from A to Z at the end of the name, how do i do so?

After i append the name, i need to check again to see if the added name already exist too.

thanks...

Reply With Quote
  #2  
Old October 1st, 2002, 11:22 AM
justin_dago justin_dago is offline
Contributing User
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Apr 2002
Location: new york
Posts: 84 justin_dago User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 7
Quote:
i need to check if a name(string) is already in database and if it is in, i need to add alphabets from A to Z at the end of the name, how do i do so?


you may want to clarify a bit...

you want to add all the characters from A to Z, a random set of say 4???

Reply With Quote
  #3  
Old October 1st, 2002, 07:28 PM
peter83 peter83 is offline
Member
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Aug 2002
Posts: 19 peter83 User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 0
i need to add only one alphabet at the back if it exist. for example, Micheal Brown already exist, then i add A to it and it becomes Micheal Brown A, then if Micheal Brown A exist then i add B and it becomes Micheal Brown B..

Reply With Quote
  #4  
Old October 9th, 2002, 10:43 PM
peter83 peter83 is offline
Member
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Aug 2002
Posts: 19 peter83 User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 0
does anyone knows??? pls help...

thanks...

Reply With Quote
  #5  
Old October 10th, 2002, 09:14 AM
jfhiller jfhiller is offline
Junior Member
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Oct 2002
Posts: 1 jfhiller User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 0
Send a message via AIM to jfhiller
I think this should be pretty simple with a loop or a couple of nested loops. You could make a String or char[] with the letters of the alphabet, and append "i" char to the end of your original string as you loop through. You can define a global boolean and use that in your outer while loop condition. Then, your inner loop can set a boolean variable appropriately for what it finds.

Reply With Quote
  #6  
Old October 10th, 2002, 10:05 PM
peter83 peter83 is offline
Member
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Aug 2002
Posts: 19 peter83 User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: < 1 sec
Reputation Power: 0
can u show me the codes???

thank you so much..

Reply With Quote
Reply

Viewing: Dev Shed ForumsProgramming LanguagesJava Help > add alphabets to a string


Thread Tools  Search this Thread 
Search this Thread:

Advanced Search
Display Modes  Rate This Thread 
Rate This Thread:


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
View Your Warnings | New Posts | Latest News | Latest Threads | Shoutbox
Forum Jump


Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
  
 





© 2003-2008 by Developer Shed. All rights reserved. DS Cluster 5 hosted by Hostway