help-octave
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: xlswrite : create xls with several worksheet


From: Philip Nienhuis
Subject: Re: xlswrite : create xls with several worksheet
Date: Fri, 22 Apr 2016 20:54:28 +0200
User-agent: Mozilla/5.0 (Windows NT 6.1; WOW64; rv:43.0) Gecko/20100101 Firefox/43.0 SeaMonkey/2.40

Nicholas Jankowski wrote:
On Fri, Apr 22, 2016 at 1:46 PM, Nicholas Jankowski <address@hidden> wrote:
On Fri, Apr 22, 2016 at 12:39 PM, PhilipNienhuis <address@hidden> wrote:
NJank wrote
in the meantime, shouldn't xlswrite return a 0? is xlswrite unaware of
the zip.m file creation error? if so that may be worth it's own bug
report.

You mean for the file creation error? No I don't think so, it really is
another issue:
The actual bug to fix is that xlswrite and xlsread happily accept an empty
file name (even if silently derived from a subdir name) and append it an
extension anyway, instead of insisting on a valid filename.

personally, I think these are separate bugs.

1 - xlswrite gets a non-empty filename (his last example did provide a
valid filename), but because the folder doesn't exist it fails to
create the file, produces no error, and returns a 1, which is supposed
to mean a successful write operation.

2 - xlswrite accepts an empty filename... and other strange things ensue.

I managed to try with Matlab (note: "testsubdir\" is nonexistent):

>>  xlswrite ('testsubdir\test.xlsx', rand (3), 'Sh_A', 'B3:D5')
Error using xlswrite (line 219)
Invoke Error, Dispatch Exception:
Source: Microsoft Excel
Description: SaveAs method of Workbook class failed
Help File: xlmain11.chm
Help Context ID: 0

I'll look into fixing the issues soon.

Thanks,

Philip




reply via email to

[Prev in Thread] Current Thread [Next in Thread]