# Opening tab-delimited file in Calc on Windows

Windows 7 and LO 6.0.1.1 64 bit

I have a number of tab-delimited files, with a file extension of .txt or .ods or .csv or .xls

When I open Calc, then use File/Open to open a tab-delimited file, the file always opens in Writer. I don't get the dialog allowing me to specify the column separator, etc

I have various versions of LO4 and LO5 and they show the same problem. Also the same with Windows 10

However, various versions of OpenOffice work fine, as does LibreOffice on Linux...... I get the dialog allowing me to specify the column separator, and the data opens in Calc

Any ideas?

edit retag close merge delete

@David: Would you mind to mark the parts of the question edited by you?
BTW There is also a user DAVID written in upper case and I couldn't insert the usual @David ("David") here at the start of the comment without getting it changed to upper case.

( 2018-03-08 13:05:27 +0100 )edit

Hi @Lupp - I only added the "windows-7" tag, and the "...on Windows" part in the question title, since this was explicitly delimited in OP's text. Hope that helps! || It's odd that title revisions are not part of the general revision history; you can get that (normally) by clicking the revision date in the upper right of the question, or by manually changing the URL to: .../questions/123456/revisions/ (note the "s" on the end of "questions"). FWIW!

( 2018-03-08 16:22:58 +0100 )edit

Sort by » oldest newest most voted

If it has file name extension .txt it will open in Writer, if it is .csv it will open in Calc. To force a .txt file to open in Calc you'll have to select the Text - txt - csv (StarCalc) filter when opening the file, or open it when having already another spreadsheet open as the current document (can be a new empty document).

more

The files will not open in Calc regardless of extension. When I open a .txt file in Calc, I am given no opportunity to select the Text-txt-csv filter. The file just immediately opens in Writer. I already have Calc open when I try to open a tab-delimited file. From the Calc menu, I use FILE/OPEN and select the .txt file and it just opens in Writer

( 2018-03-09 13:51:15 +0100 )edit

If a .ods file actually is a table in plain text (delimited by tab or otherwise) the extension is lying. Eliminate this nonsense first.

LibO will assume Writer the applicable component for text files. If you want to order it otherwise permanently you need to change the assignments to extensions for each concerned one for your OS giving scalc.exe instead of soffice.exe as the application. (Not recommended.)
You can open a plain-text file inside Calc when inserting a sheet 'From file'.
Also possible: Use a command interpreter ('Execute' tool probably) and enter something like
"C:\Program Files\LibreOffice\program\soffice.exe" -calc "C:\Users\MyUserName\documents\MyFurtherFolderPath\MyFileName.csv"

more

The file extension should only matter if I am double-clicking on the file to open it in Windows using the default application. When opening from within Calc using FILE/OPEN, the extension should not matter. It certainly does not matter when using OpenOffice, or LibreOffice on Linux. That works fine. As does Excel on Windows. And using such a command in a command line interpreter is total overkill for such a problem. I tried SHEET/INSERT SHEET FROM FILE and the resultant dialog has OK greyed out

( 2018-03-09 13:58:31 +0100 )edit

And I should emphasise that using OpenOffice on Windows or LibreOffice on Linux, I can open a tab-delimited file in Calc using FILE/OPEN or SHEET/INSERT SHEET FROM FILE. Both provide the dialog to select the column separator, etc. And I have uninstalled LO and downloaded a fresh copy. Still have the problem

( 2018-03-09 14:02:50 +0100 )edit

Well, of course I don't actually use the commanmd line for the purpose. The hnt was for cpmpleteness.
On my Win-10-system .csv is asociated with soffice.exe (not specifically with scalc.exe). LibO opens the files automatically in Calc.if they actually contain plain text.
A plain text file wrongly given the extension .ods is opened in Writer. I don't worry about if this is clever. I don't use lying extensions. Opening it from a running Calc the same file opens in Calc.

( 2018-03-09 15:48:08 +0100 )edit

If you have actually wrong behaviour insofar beyond the probability of lying extensions on Win, you may check if your user profile is corrupted. Plain text files with extension .txt are openedin Calc from running Calc.
I keep also a facultative 'Open With' scalc.exe on my system for .txt files. It works as expected,; the dialog for csv import is opened.

( 2018-03-09 15:52:55 +0100 )edit