Ask Your Question
0

Opening tab-delimited file in Calc on Windows

asked 2018-03-08 11:06:22 +0200

kiloran gravatar image

updated 2018-03-08 12:06:52 +0200

David gravatar image

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 flag offensive close merge delete

Comments

@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.

Lupp gravatar imageLupp ( 2018-03-08 13:05:27 +0200 )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!

David gravatar imageDavid ( 2018-03-08 16:22:58 +0200 )edit

2 Answers

Sort by » oldest newest most voted
0

answered 2018-03-08 13:04:35 +0200

erAck gravatar image

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).

edit flag offensive delete link more

Comments

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

kiloran gravatar imagekiloran ( 2018-03-09 13:51:15 +0200 )edit
0

answered 2018-03-08 13:02:31 +0200

Lupp gravatar image

updated 2018-03-08 13:03:35 +0200

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"

edit flag offensive delete link more

Comments

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

kiloran gravatar imagekiloran ( 2018-03-09 13:58:31 +0200 )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

kiloran gravatar imagekiloran ( 2018-03-09 14:02:50 +0200 )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.

Lupp gravatar imageLupp ( 2018-03-09 15:48:08 +0200 )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.

Lupp gravatar imageLupp ( 2018-03-09 15:52:55 +0200 )edit
Login/Signup to Answer

Question Tools

1 follower

Stats

Asked: 2018-03-08 11:06:22 +0200

Seen: 440 times

Last updated: Mar 08 '18