Results 1 to 3 of 3
  1. #1
    3 Star Lounger
    Join Date
    Apr 2001
    Location
    Warrington, Cheshire
    Posts
    355
    Thanks
    3
    Thanked 0 Times in 0 Posts

    Save as csv creates trailing space

    have an excel sheet where saving as file format xlCSV keeps all of the columns but one column is having a trailing space added to the text.



    when the file is saved, it adds a trailing space to the PAYCODE entries so 'LSHR' becomes 'LSHR '

    Anyone come across this previously?
    thanks
    Last edited by ase001; 2016-02-01 at 09:15. Reason: table not appearing

  2. #2
    WS Lounge VIP
    Join Date
    Dec 2009
    Location
    Earth
    Posts
    8,199
    Thanks
    48
    Thanked 987 Times in 917 Posts
    As a CSV, the fields should be enclosed in quotes, e.g. "LSHR ". Is this what you see?
    Do you have a further column in the spreadsheet that contains a space?

    cheers, Paul

  3. #3
    3 Star Lounger
    Join Date
    Apr 2001
    Location
    Warrington, Cheshire
    Posts
    355
    Thanks
    3
    Thanked 0 Times in 0 Posts

    solved

    Thanks Paul No there is no column with a space in it..however, I have just managed to solve it.
    The problem arises when the formatting of the column is indented and vertical centre.
    I set the formatting to left basic cells and the column now saves as csv without the trailing space.

    bit of a gotcha problem with the formatting dictating the resulting csv output.

    thanks for checking Paul.

Posting Permissions

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