Fractal Softworks Forum

Please login or register.

Login with username, password and session length

Author Topic: PSA: Character encoding in Excel is wrong by default  (Read 1863 times)

kazi

  • Admiral
  • *****
  • Posts: 714
    • View Profile
PSA: Character encoding in Excel is wrong by default
« on: November 21, 2014, 11:10:50 PM »

This is something I've known for awhile, and has caused me no small amount of pain. I just about lost it tonight when I noticed it was causing me issues while editing rules.csv. Creating this PSA to spare others my pain haha...

EXCEL ENCODES EVERYTHING IN THE WRONG FORMAT BY DEFAULT. DO NOT USE EXCEL FOR EDITING STARSECTOR-RELATED CSV FILES.

If you're getting perplexing errors and have no idea where they are coming from even when all of the files look exactly as they should, there's a chance that Excel is saving all of your files in ANSI format rather than UTF-8 (without BOM). Starsector uses UTF-8 (without BOM). This can cause any number of issues, from improperly displayed text, to a full on CTD.

You can detect the currently used encoding in Notepad++ clicking on the Encoding menu at the top and seeing what's selected.

In the event you are using the wrong encoding, you can it in Notepad++ by selecting Encoding>Convert to UTF-8 without BOM. Problem solved. Additionally, LibreOffice has significantly less trouble saving in the correct format. It's also free.
Logged

Debido

  • Admiral
  • *****
  • Posts: 1183
    • View Profile
Re: PSA: Character encoding in Excel is wrong by default
« Reply #1 on: November 22, 2014, 01:29:17 AM »

*Shrug* I'm running Excel and has always encoded in UTF-8 without BOM....So...um, some sort of local setting on your Excel? The version of Excel you're using? I'm currently running with the latest version of Excel.
Logged

Lcu

  • Commander
  • ***
  • Posts: 213
    • View Profile
Re: PSA: Character encoding in Excel is wrong by default
« Reply #2 on: November 22, 2014, 06:30:04 AM »

Yeah, i'm using excel too and it saved the .csv files in UTF-8 (without BOM) however this time i tried but the .csv crashed the game.
Logged
Spoiler
66766766
66766766
66666766
66766766
66766766
Ctrl+F, type 6
[close]