It looks like Tara handles this correctly for spreadsheets (but not for csv
files):

   load '~addons/tara.ijs'
   readexcel 'c:\amisc\Book2.xls'
+-----------------------------------+
|This is a single line              |
+-----------------------------------+
|This line has multiple lines in it.|
+-----------------------------------+
   'l1 l2'=. readexcel 'c:\amisc\Book2.xls'
   l1
This is a single line
   l2
This line
has multiple
lines in it.
   a. i. l2
84 104 105 115 32 108 105 110 101 10 104 97 115 32 109 117 108 116 105 112
108 101 10 108 105 110 101 115 32 105 110 32 105 116 46



On Tue, Oct 27, 2009 at 11:17 AM, R.E. Boss <[email protected]> wrote:

> Not confirmed:
>
>   [dat=.a. i. wd'clippaste'
> 97 9 34 98 10 99 10 100 34 9 101 13 10
>
>   fixcsv dat{a.
> +------------+
> |a "b c d" e |
> +------------+
>
>
> R.E. Boss
>
>
> > -----Oorspronkelijk bericht-----
> > Van: [email protected] [mailto:programming-
> > [email protected]] Namens bill lam
> > Verzonden: dinsdag 27 oktober 2009 15:53
> > Aan: JProgramming
> > Onderwerp: [Jprogramming] force line breaks in csv
> >
> > text inside a spreadsheet cell can be multiline by forcing line break
> > using alt-enter in window and linux.  I found that block of cells
> > containing line break can be copy-and-paste within spreadsheet. But
> > csv verbs inside J base library seemed cannot handle that.
> >
> > eg, for cells
> > -+-+-+
> > |a|b|e|
> > | |c| |
> > | |d| |
> > +-+-+-+
> > |a|a|a|
> > +-+-+-+
> >
> > clipboard of csv as reported by wd'clippaste' will be
> >   97 9 98 10 99 10 100 9 101 10 97 9 97 9 97{a.
> >
> > but
> >    load 'csv'
> >    fixcsv dat=. 97 9 98 10 99 10 100 9 101 10 97 9 97 9 97{a.
> > +---+
> > |a b|
> > +---+
> > |c  |
> > +---+
> > |d e|
> > +---+
> >
> > which is not the 2x3 block.
> >
> > --
> > regards,
> > ====================================================
> > GPG key 1024D/4434BAB3 2008-08-24
> > gpg --keyserver subkeys.pgp.net --recv-keys 4434BAB3
> > ----------------------------------------------------------------------
> > For information about J forums see http://www.jsoftware.com/forums.htm
>
> ----------------------------------------------------------------------
> For information about J forums see http://www.jsoftware.com/forums.htm
>



-- 
Devon McCormick, CFA
^me^ at acm.
org is my
preferred e-mail
----------------------------------------------------------------------
For information about J forums see http://www.jsoftware.com/forums.htm

Reply via email to