Gnumeric - How to have Windows newline character?

Word processors, spreadsheets, presentations, translation, etc.
Post Reply
Message
Author
jpr
Posts: 102
Joined: Thu 02 Apr 2009, 01:30

Gnumeric - How to have Windows newline character?

#1 Post by jpr »

Hi,

I am using Puppy-421. It came with Gnumeric which is great.
I need to move my work between Puppy and Windows.
If I create a spreadsheet in Gnumeric and save it as .xls then I can open it in Excel in Windows. But I have one problem.
If a cell contains a multi-line text (created using ALT + Enter), then the newline character is encoded Linux-style and Excel does not read it correctly. It shows a little square where the newline character should be.
How do I work around this, other than manually editing all bad entries?

Thanks.

jpeps
Posts: 3179
Joined: Sat 31 May 2008, 19:00

Re: Gnumeric - How to have Windows newline character?

#2 Post by jpeps »

jpr wrote:Hi,

I am using Puppy-421. It came with Gnumeric which is great.
I need to move my work between Puppy and Windows.
If I create a spreadsheet in Gnumeric and save it as .xls then I can open it in Excel in Windows. But I have one problem.
If a cell contains a multi-line text (created using ALT + Enter), then the newline character is encoded Linux-style and Excel does not read it correctly. It shows a little square where the newline character should be.
How do I work around this, other than manually editing all bad entries?

Thanks.
Strange...saving in xlsx loads up fine in OO. I tested with ver 1.10.1

User avatar
fluxit
Posts: 326
Joined: Sat 24 Jun 2006, 04:14
Location: Ketchikan, AK USA

Re: Gnumeric - How to have Windows newline character?

#3 Post by fluxit »

jpr wrote:How do I work around this, other than manually editing all bad entries?
Have you tried saving in all of the xls variants that gnumeric allows?

What about odf/ods? I was under the impression that there were import filters available for MS Office that allow for the use of odf documents.

Does Excel have search and replace?

You could fix the bug in gnumeric's xls support or write a macro for Excel :)

amigo
Posts: 2629
Joined: Mon 02 Apr 2007, 06:52

#4 Post by amigo »

There are a couple of tools to convert any sort of plain-text files between unix/dos.
unix2dos/dos2unix
fromdos/todos

One pair of these should available on any half-complete distro you choose.

User avatar
RetroTechGuy
Posts: 2947
Joined: Tue 15 Dec 2009, 17:20
Location: USA

#5 Post by RetroTechGuy »

amigo wrote:There are a couple of tools to convert any sort of plain-text files between unix/dos.
unix2dos/dos2unix
fromdos/todos

One pair of these should available on any half-complete distro you choose.
For text operations, there is also a program called "flip"

for dos endings:

Code: Select all

flip -m filename
for linux endings:

Code: Select all

flip -u filename
And the Debian package works fine (probably need no additional dependencies):

http://packages.debian.org/squeeze/flip

http://http.us.debian.org/debian/pool/m ... 1_i386.deb
[url=http://murga-linux.com/puppy/viewtopic.php?t=58615]Add swapfile[/url]
[url=http://wellminded.net63.net/]WellMinded Search[/url]
[url=http://puppylinux.us/psearch.html]PuppyLinux.US Search[/url]

jpeps
Posts: 3179
Joined: Sat 31 May 2008, 19:00

#6 Post by jpeps »

gnumeric has ssconvert.

example:
ssconvert --export-type=Gnumeric_Excel:excel_dsf foo.gnumeric foo.xls

http://linux.die.net/man/1/ssconvert

Code: Select all

~ $ sudo ssconvert --list-exporters
ID                           | Description
Gnumeric_Excel:xlsx          | MS Excel (tm) 2007
Gnumeric_Excel:excel_dsf     | MS Excel (tm) 97/2000/XP & 5.0/95
Gnumeric_Excel:excel_biff7   | MS Excel (tm) 5.0/95
Gnumeric_Excel:excel_biff8   | MS Excel (tm) 97/2000/XP
Gnumeric_dif:dif             | Data Interchange Format (*.dif)
Gnumeric_glpk:glpk           | GLPK Linear Program Solver
Gnumeric_lpsolve:lpsolve     | LPSolve Linear Program Solver
Gnumeric_html:roff           | TROFF (*.me)
Gnumeric_html:latex_table    | LaTeX 2e (*.tex) table fragment
Gnumeric_html:latex          | LaTeX 2e (*.tex)
Gnumeric_html:xhtml_range    | XHTML range - for export to clipboard
Gnumeric_html:xhtml          | XHTML (*.html)
Gnumeric_html:html40frag     | HTML (*.html) fragment
Gnumeric_html:html40         | HTML 4.0 (*.html)
Gnumeric_html:html32         | HTML 3.2 (*.html)
Gnumeric_OpenCalc:odf        | ODF/OpenOffice with foreign elements (*.ods)
Gnumeric_OpenCalc:openoffice | ODF/OpenOffice without foreign elements (*.ods)
Gnumeric_sylk:sylk           | MultiPlan (SYLK)
Gnumeric_stf:stf_csv         | Comma separated values (CSV)
Gnumeric_stf:stf_assistant   | Text (configurable)
Gnumeric_XmlIO:sax           | Gnumeric XML (*.gnumeric)
Gnumeric_pdf:pdf_assistant   | PDF export
~ $ 

aragon
Posts: 1698
Joined: Mon 15 Oct 2007, 12:18
Location: Germany

Re: Gnumeric - How to have Windows newline character?

#7 Post by aragon »

jpr wrote:Hi,

I am using Puppy-421. It came with Gnumeric which is great.
I need to move my work between Puppy and Windows.
If I create a spreadsheet in Gnumeric and save it as .xls then I can open it in Excel in Windows. But I have one problem.
If a cell contains a multi-line text (created using ALT + Enter), then the newline character is encoded Linux-style and Excel does not read it correctly. It shows a little square where the newline character should be.
How do I work around this, other than manually editing all bad entries?

Thanks.
Well, maybe i'm thinking to simple but the best way should be to not use newlines within cells. This allways leads to conversion problems (same as combined cells and such things).

aragon

Post Reply