External Table Editor (ModernCSV) and Table DAT issues

Hello.
I am using ModernCSV to edit my tables.
I put in a Table DAT and hit Edit (I’ve already set my editor to be ModernCSV).
Touch Designer outputs a .py Python file.
ModernCSV edits this and resaves as .py.
But now my Table DAT is full of commas, the cells have vanished.

I’ve also tried making a new Table DAT, Edit in ModernCSV, save as CSV file, drag/drop the new CSV file into Touch and the table is good. No commas, cells are correct.
But if I Edit using the external editor and resave back as the same CSV file its back to being full of commas and no cells.

Is there a way to get around this or some method I should be following?
Do I need to save as a CSV file and re-import each time?

Thanks!

I use ModernCSV also and haven’t had this problem. It has an option to set delimiter under File->Save Options. What you really want is actually TAB separated values.

1 Like

I looked under Settings, didn’t realize there would be a Save Options under the File menu.

Changing to Tabs delimiter works like a charm.

With each new Table DAT and Edit I have to re-select the Tab format. Once its set for a file ModernCSV keeps the Tabs but I have to set it for every file.

Is there a way to default ModernCSV to the tabs?
Thanks!

Mine defaults to tabs so I don’t know what to tell you except to dig around in there or through help.

Edit:
I figured it out. If you add a Table.DAT and then immediately click Edit without adding anything you’ll get commas from ModernCSV. You can use Save Options to avoid this.

If you add 1 empty column to the Table.DAT before you use Edit then ModernCSV will see the tabs in the file and use tabs instead of commas.

To set a default of tabs for .py files go to Preferences>File Extension Options and add an entry for .py files with \t for delimiter. I used the same settings as the other files for the rest of the options.

Edit addition:
Under Preferences>Edit Settings look for “Save After Each Edit” and set to True. This will eliminate the need to Save the file before returning to TD. Make changes and go back and you’re done. This is a feature that ModernCSV has added at the request of TD users. Awesome!!!

1 Like

Great find! Thanks for posting this info

Thank you for pushing me in the right direction!