Results 1 to 4 of 4
  1. #1
    karayi is offline Member
    Join Date
    Oct 2013
    Posts
    1
    Rep Power
    0

    Default Line feed question

    Hi Javaplus,

    I am facing the same problem, could you please let me know how you used the enter key code, please post the code snippet.


    Thanks

  2. #2
    SurfMan's Avatar
    SurfMan is offline Godlike
    Join Date
    Nov 2012
    Location
    The Netherlands
    Posts
    946
    Rep Power
    2

    Default Re: line feed in CSV

    This thread is 5 and a half years old. It's dead.

    So, to answer your question (if it can be called a question), append "\r\n" to the line in order to let Windows understand line endings. Using Character.LINE_SEPARATOR is not going to work if you produce the file on *nix and read the result on Windows.

    In the mean time, read this: java - Do line endings differ between Windows and Linux? - Stack Overflow

  3. #3
    Junky's Avatar
    Junky is offline Grand Poobah
    Join Date
    Jan 2011
    Location
    Dystopia
    Posts
    3,798
    Rep Power
    7

    Default Re: line feed in CSV

    For platform independent code you should use System.getProperty();

  4. #4
    Tolls is offline Moderator
    Join Date
    Apr 2009
    Posts
    12,009
    Rep Power
    20

    Default Re: Line feed question

    Moved from this thread:
    line feed in CSV
    Please do not ask for code as refusal often offends.

    ** This space for rent **

Similar Threads

  1. Command line menu question
    By Gagnrath in forum New To Java
    Replies: 5
    Last Post: 07-29-2013, 08:52 PM
  2. Very simple question about creating a string line
    By wfsteadman in forum New To Java
    Replies: 1
    Last Post: 02-09-2013, 07:57 PM
  3. Command line question
    By dougie1809 in forum New To Java
    Replies: 1
    Last Post: 03-09-2012, 01:40 PM
  4. Question about Line object w/ switch case
    By kraigballa in forum New To Java
    Replies: 8
    Last Post: 10-11-2011, 08:00 PM
  5. line feed in CSV
    By javaplus in forum New To Java
    Replies: 2
    Last Post: 01-24-2008, 03:46 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •