#1
  1. No Profile Picture
    Contributing User
    Devshed Newbie (0 - 499 posts)

    Join Date
    Nov 2001
    Posts
    194
    Rep Power
    13

    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. #2
  3. No Profile Picture
    Moderator =(8^(|)
    Devshed Intermediate (1500 - 1999 posts)

    Join Date
    Feb 2002
    Location
    Sacramento, CA
    Posts
    1,710
    Rep Power
    14
    Are they entering the text in a textarea? If they are, the lines will be terminated with "\n".
  4. #3
  5. No Profile Picture
    Contributing User
    Devshed Newbie (0 - 499 posts)

    Join Date
    Nov 2001
    Posts
    194
    Rep Power
    13
    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.
    Web Development Studio | XML/ XSL/ PHP/ Flash/ Mysql | Digital Metamorphoses |
    http://www.dimensionstudio.biz
  6. #4
  7. No Profile Picture
    Moderator =(8^(|)
    Devshed Intermediate (1500 - 1999 posts)

    Join Date
    Feb 2002
    Location
    Sacramento, CA
    Posts
    1,710
    Rep Power
    14
    Ok. Look for "\n" or "\r\n" depending on what platform you're running on.

IMN logo majestic logo threadwatch logo seochat tools logo