www.delorie.com/archives/browse.cgi   search  
Mail Archives: cygwin/2010/02/07/04:26:53

X-Recipient: archive-cygwin AT delorie DOT com
X-SWARE-Spam-Status: No, hits=-1.8 required=5.0 tests=AWL,BAYES_00,SARE_MSGID_LONG40,SPF_PASS
X-Spam-Check-By: sourceware.org
MIME-Version: 1.0
In-Reply-To: <201002051159.o15BxfJL009697@beta.mvs.co.il>
References: <a74950d41002041055y32b83ae9va3e752cd4007dff AT mail DOT gmail DOT com> <201002051159 DOT o15BxfJL009697 AT beta DOT mvs DOT co DOT il>
Date: Sun, 7 Feb 2010 10:26:37 +0100
Message-ID: <a74950d41002070126m34f443c8re0ebd6c46aafde43@mail.gmail.com>
Subject: Re: xls to text conversion ?
From: Maarten Vanneste <maarten DOT w DOT b DOT vanneste AT gmail DOT com>
To: ehud AT unix DOT mvs DOT co DOT il
Cc: cygwin AT cygwin DOT com
X-IsSubscribed: yes
Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm
List-Id: <cygwin.cygwin.com>
List-Unsubscribe: <mailto:cygwin-unsubscribe-archive-cygwin=delorie DOT com AT cygwin DOT com>
List-Subscribe: <mailto:cygwin-subscribe AT cygwin DOT com>
List-Archive: <http://sourceware.org/ml/cygwin/>
List-Post: <mailto:cygwin AT cygwin DOT com>
List-Help: <mailto:cygwin-help AT cygwin DOT com>, <http://sourceware.org/ml/#faqs>
Sender: cygwin-owner AT cygwin DOT com
Mail-Followup-To: cygwin AT cygwin DOT com
Delivered-To: mailing list cygwin AT cygwin DOT com

Dear all,

I did not manage to get the perl codes running properly, but then
again, I did not invest too much time in it and I am not familiar with
perl.

I did come across a xls2csv executable, which runs smoothly under
cygwin and can be easily lined up with (g)awk and sed to get to what I
wanted.

Thanks for your suggestions !

With best regards / Vennlig hilsen
Maarten





On Fri, Feb 5, 2010 at 12:59 PM, Ehud Karni <ehud AT unix DOT mvs DOT co DOT il> wrote:
> On Thu, 4 Feb 2010 19:55:36 Maarten Vanneste wrote:
>>
>> Dear all,
>> I was wondering whether there is a cygwin tool/program which converts
>> microsoft excel files to text. Any suggestions ?
>
> I use xlhtml, source at: =A0http://chicago.sourceforge.net/xlhtml/
>
> I applied the following patch:
>
> diff -c ~/xlhtml-0.5/xlhtml/xlhtml.h-org ~/xlhtml-0.5/xlhtml/xlhtml.h
> *** ~/xlhtml-0.5/xlhtml/xlhtml.h-org =A0 =A0Thu Apr 11 03:23:51 2002
> --- ~/xlhtml-0.5/xlhtml/xlhtml.h =A0 =A0 =A0 =A0Thu Dec 24 18:16:51 2009
> ***************
> *** 20,28 ****
> =A0#include "version.h"
>
> =A0/* Used by packed string array Opcode: 0xFC */
> ! #define HARD_MAX_ROWS_97 =A0 =A0 =A00x7FFE =A0 =A0/*!< Used in add_wb_a=
rray to prevent OOM */
> ! #define HARD_MAX_ROWS_95 =A0 =A0 =A00x3FFF =A0 =A0/*!< Used in add_wb_a=
rray to prevent OOM */
> ! #define HARD_MAX_COLS =A0 =A0 =A0 =A0 256 =A0 =A0 =A0 =A0 =A0 /*!< Used=
 in add_wb_array to prevent OOM */
>
> =A0static U16 HARD_MAX_ROWS =3D HARD_MAX_ROWS_97;
> =A0/**********************************
> --- 20,28 ----
> =A0#include "version.h"
>
> =A0/* Used by packed string array Opcode: 0xFC */
> ! #define HARD_MAX_ROWS_97 =A0 =A0 =A00x0FFFF =A0 /*!< Used in add_wb_arr=
ay to prevent OOM */
> ! #define HARD_MAX_ROWS_95 =A0 =A0 =A00x07FFF =A0 /*!< Used in add_wb_arr=
ay to prevent OOM */
> ! #define HARD_MAX_COLS =A0 =A0 =A0 =A0 256 =A0 =A0 =A0 /*!< Used in add_=
wb_array to prevent OOM */
>
> =A0static U16 HARD_MAX_ROWS =3D HARD_MAX_ROWS_97;
> =A0/**********************************
> ***************
> *** 57,63 ****
> =A0 =A0 =A0 =A0U16 type; =A0 =A0 =A0 /*!< This will record the record typ=
e that generated the cell */
> =A0 =A0 =A0 =A0U16 spanned; =A0 =A0 =A0 =A0 =A0 =A0/*!< If 1 don't output=
 */
> =A0 =A0 =A0 =A0uni_string ustr; =A0 =A0 =A0 =A0/*!< The cell's displayed =
contents */
> ! =A0 =A0 =A0 U16 rowspan; =A0 =A0 =A0 =A0 =A0 =A0/*!< rows to span */
> =A0 =A0 =A0 =A0U16 colspan; =A0 =A0 =A0 =A0 =A0 =A0/*!< columns to span */
> =A0 =A0 =A0 =A0uni_string h_link; =A0 =A0 =A0/*!< If a hyperlinked cell, =
this is the link*/
> =A0}cell;
> --- 57,63 ----
> =A0 =A0 =A0 =A0U16 type; =A0 =A0 =A0 /*!< This will record the record typ=
e that generated the cell */
> =A0 =A0 =A0 =A0U16 spanned; =A0 =A0 =A0 =A0 =A0 =A0/*!< If 1 don't output=
 */
> =A0 =A0 =A0 =A0uni_string ustr; =A0 =A0 =A0 =A0/*!< The cell's displayed =
contents */
> ! =A0 =A0 =A0 U32 rowspan; =A0 =A0 =A0 =A0 =A0 =A0/*!< rows to span */
> =A0 =A0 =A0 =A0U16 colspan; =A0 =A0 =A0 =A0 =A0 =A0/*!< columns to span */
> =A0 =A0 =A0 =A0uni_string h_link; =A0 =A0 =A0/*!< If a hyperlinked cell, =
this is the link*/
> =A0}cell;
>
>
> I did it on GNU/Linux but I think it'll work well on Cygwin.
>
> It worked for several years in our company without the patch, but
> lately we started receiving Excel files with 65535 lines in one sheet,
> so I had to change the hard coded line limit.
>
> Ehud.
>
>
> --
> =A0Ehud Karni =A0 =A0 =A0 =A0 =A0 Tel: +972-3-7966-561 =A0/"\
> =A0Mivtach - Simon =A0 =A0 =A0Fax: +972-3-7976-561 =A0\ / =A0ASCII Ribbon=
 Campaign
> =A0Insurance agencies =A0 (USA) voice mail and =A0 X =A0 Against =A0 HTML=
 =A0 Mail
> =A0http://www.mvs.co.il =A0FAX: =A01-815-5509341 =A0/ \
> =A0GnuPG: 98EA398D <http://www.keyserver.net/> =A0 =A0Better Safe Than So=
rry
>

--
Problem reports:       http://cygwin.com/problems.html
FAQ:                   http://cygwin.com/faq/
Documentation:         http://cygwin.com/docs.html
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019