|
|
|
| |||||||||
![]() |
|
|
«
Previous Thread
|
Next Thread
»
|
Thread Tools | Search this Thread | Rate Thread | Display Modes |
|
#1
|
|||
|
|||
|
capturing "enter" command in a string
hello..i want a user to type a para and input that into my java program. But i am not able to caputre the 'enter' and so i get one long line of string. I am using stringbuffer to do this!
please help.
__________________
Web Development Studio | XML/ XSL/ PHP/ Flash/ Mysql | Digital Metamorphoses | http://www.dimensionstudio.biz |
|
#2
|
|||
|
|||
|
Are they entering the text in a textarea? If they are, the lines will be terminated with "\n".
|
|
#3
|
|||
|
|||
|
NO THEY ARE NOT....they are simply typing it a shell..and pressing enter..and thsi text is taken in by the java program and stored in a StringBuffer.
|
|
#4
|
|||
|
|||
|
Ok. Look for "\n" or "\r\n" depending on what platform you're running on.
|
![]() |
| Viewing: Dev Shed Forums > Programming Languages > Java Help > capturing "enter" command in a string |
| Thread Tools | Search this Thread |
| Display Modes | Rate This Thread |
|
|
|
|