Hello Jean,

charbar wrote:
>
>
> PhilipNienhuis wrote:
<snip>
>> As an aside, has anybody really tried the xls/ods scripts? I'd really
>> appreciate wider use&  testing....&  suggestions for improvement.
<snip>
> When I run an .m file that calls odswrite, Octave readouts that it is

Well, first of all: thank you for trying....

> creating the file and then returns the following errors immediately
> thereafter:
>
> Supported interfaces: warning: split is obsolete and will be removed from a
> fut
> ure version of Octave; please use strsplit instead

That strsplit message comes from the java package, from javaclasspath.m

In octave-forge svn there's a newer java package version being prepared 
by a.o., Martin Hepperle, but finalizing that will take some more time.

>   Java/ODFtoolkit (OTK) OK.  Java/jOpenDocument (JOD) OK.
>>>> error: Currently ods2oct can only read reliably from .ods files
> error: called from:
> error:   /home/charles/octave/io-1.0.13/odsopen.m at line 135, column 3
> error:   /home/charles/octave/io-1.0.13/odswrite.m at line 98, column 6
> error:   /home/charles/Desktop/M-files/(my_file_name).m at line 42, column 1
>
> Why is it saying that ods2oct can only read .ods files? I don't think the
<snip>

As a general remark, please show the exact Octave statements that lead 
to this error. Otherwise we'll have to guess under what circumstances 
the error occurs, and that doesn't quite help us understand what went wrong.

In this case however you're a bit lucky:
If you'd check the code in odsopen, you'll see the reason:
odsopen.m checks for an explicit ".ods" extension (w/o quotes).
That's because (AFAIK) the older OpenOffice.org formats are not 
supported (though I suspect that jOpenDocument can read it, but I've 
never tried - I haven't got old .sxc files lying around for testing).

Hint: it can often be very enlightening to first see for yourself why 
error messages arise; that's one of the reason Octave spews out so much 
info about where, in which source file, an error occurs.

I'll adapt the help text of odswrite to emphasize that extensions should 
be specified explicitly, OK?

> I believe I have everything I need in the right place, but maybe I don't.

AFAICS you got all the jars in place - I see no Octave complaints about 
that.

BTW Which versions of odfdom.jar & jopendocument.jar do you have? I'd 
advise odfdom 0.8.6 and jOpenDocument 1.2b3 or newer.
I will drop support for earlier odfdom & jopendocument versions in a 
next io pkg release anyway.

> I've listed further information below to tell you about my setup. Any ideas?

Specify the extension in odswrite like:
rstatus = odswrite ('somespreadsheetfile.ods', ..............)

Philip

------------------------------------------------------------------------------
Nokia and AT&T present the 2010 Calling All Innovators-North America contest
Create new apps & games for the Nokia N8 for consumers in  U.S. and Canada
$10 million total in prizes - $4M cash, 500 devices, nearly $6M in marketing
Develop with Nokia Qt SDK, Web Runtime, or Java and Publish to Ovi Store 
http://p.sf.net/sfu/nokia-dev2dev
_______________________________________________
Octave-dev mailing list
Octave-dev@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/octave-dev

Reply via email to