[Top][All Lists]

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

Problem with sheet identifier in xls2oct

From: Joao Rodrigues
Subject: Problem with sheet identifier in xls2oct
Date: Sat, 27 Aug 2016 12:46:58 +0200
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:45.0) Gecko/20100101 Thunderbird/45.2.0

Dear list members

I want to use older code I had to open xls data which stopped working. Essentially I cannot declare which sheet xls2oct is supposed to open. A minimal example is as follows:

I created an xlsx file with a 'Sheet1' worksheet and some content in A1:A3.

Then I run inside octave:

pkg load io
xls = xlsopen('test.xlsx');
sheetstr = 'Sheet1';
tmp = xls2oct (xls, 'Sheet1', 'A1:A3');

and I get the following error:

error: @col2num: no function and no method found
error: called from
    __OCT_xlsx2oct__ at line 301 column 12
    xls2oct at line 210 column 27
error: evaluating argument list element number 1

with the last four lines repeated several times.

But the pointer to xls seems to be fine:

xls =

  scalar structure containing the fields:

    xtype = OCT
    app = xlsx
    filename = test.xlsx
    workbook = /tmp/oct-RvkTuI
    changed = 0
    limits = [](0x0)
    sheets =

      scalar structure containing the fields:

        sh_names =
          [1,1] = Sheet1
        rid =  2
        sheetid =  1
        rels =

           2   1

If I repeat the offending command by

tmp = xls2oct (xls, 1, 'A1:A3');


tmp = xls2oct (xls,  xls.sheets.sh_names{1}, 'A1:A3');

I get the same error.

Octave version is 4.0.0
OS is Ubuntu 15.10

thank you for your help

reply via email to

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