Home Programming Excel confusing CSV file with SYLK file

Excel confusing CSV file with SYLK file

by Jack Simpson

I recently had an interesting experience whilst using pandas to write some data to a CSV file and then opening the file up with Excel to inspect its contents. To my surprise, I received a message from Excel informing me that I was attempting to open something called a ‘SYLK file’.

After doing a little digging, it appeared that if the title of the first column of a spreadsheet is ‘ID’, then Excel will automatically assume it is an SYLK file and give you grief opening it. The simplest solution I found was to rename the ID column to something a little more distinct. Now that I know that it is something that can be an issue, this will be my policy moving forward.

You may also like