help-octave
[Top][All Lists]
Advanced

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

Fwd: Re[4]: xlsread does not read a column


From: Nicholas Jankowski
Subject: Fwd: Re[4]: xlsread does not read a column
Date: Fri, 5 Aug 2016 23:55:00 -0400


---------- Forwarded message ----------
From: "Светлана Стрельникова" <address@hidden>
Date: Aug 5, 2016 10:57 PM
Subject: Re[4]: xlsread does not read a column
To: "Nicholas Jankowski" <address@hidden>
Cc:

>
> Yes, here you demonstrate the correct behaviour of xlsread.
> Actually, it worked correctly on my machine too, but a couple of days ago it changed.
> One morning it just started to behave like that (i did not turn off my computer the previous evening),
> may be it was some windows update?
>
> I re-installed octave and windows and io packages from forge, but it didn't help.
> Also I installed octave on a different machine - and got the same result, xlsread does not read columns.
> Both machines have MS Office, 2007 and 2013, respectively. Also I have Java JRE.
>
> I tried [num_array, text_array, raw_array, limits] = xlsread('test.xlsx') and got the following:
>
> Detected XLS interfaces: COM*; (* = default interface)
> num_array = 2
> text_array = {}(0x0)
> raw_array =
> {
> [1,1] = 2
> }
> limits =
>
> scalar structure containing the fields:
>
> numlimits =
>
> 1 1
> 7 7
>
> txtlimits = [](0x0)
> rawlimits =
>
> 1 1
> 7 7
> So, xlsread does see that the actuall length of a column is 7, but somehow it does not put it to the num_array. Sad.
> The only way to read columns that I have found so far is:  d= xlsread('test.xlsx', 'A1:A_very_big_number_for_my_problem_so_i'll_be_sure_that_i have_read_all_from_column) 
>
> Of course, I can previously use numlimits, to find the actuall length of the column, but it seems quite perverted to me.
>
> Thank you for your help.
>
>> Пятница, 5 августа 2016, 17:18 +03:00 от Nicholas Jankowski <address@hidden>:
>>
>>
>> On Fri, Aug 5, 2016 at 10:10 AM, Nicholas Jankowski <address@hidden> wrote:
>>>
>>> On Fri, Aug 5, 2016 at 3:04 AM, Svetlana <address@hidden> wrote:
>>>>
>>>>  Sure. Here is my xlsx-file (attached). It contains the following column:
>>>> 1
>>>> 1
>>>> 1
>>>> 1
>>>> 1
>>>> 1
>>>> 2
>>>> Here is my call of xlsread: 
>>>> clear all
>>>> clc
>>>> d=xlsread('test.xlsx') m-file and xlsx-file are in the same directory.
>>>>
>>>> Here is the result: 
>>>> Detected XLS interfaces: COM*; (* = default interface)
>>>> d = 2
>>>> d is double, size(d) is 1x1 Четверг,  4 августа 2016, 18:54 +03:00 от "NJank [via Octave]" <address@hidden>:
>>>> >
>>>
>>>
>>> Hmmm... I'm unable to recreate what you're seeing. I saved you're xslx file and got the following behavior:
>>>
>>>
>>> >> pkg load io
>>> Picked up JAVA_TOOL_OPTIONS: -Djava.vendor="New Oracle"
>>> >> xlsread('test.xlsx')
>>> Detected XLS interfaces: ans =
>>>
>>>    1
>>>    1
>>>    1
>>>    1
>>>    1
>>>    1
>>>    2
>>>
>>> >> myvar = xlsread('test.xlsx')
>>> myvar =
>>>
>>>    1
>>>    1
>>>    1
>>>    1
>>>    1
>>>    1
>>>    2
>>>
>>>
>>> If I remember correctly xlsread is a wrapper for other functions that do the actual conversion, and it can call different functions depending what's available on the system. (At least the older versions would look for installed Excel or Openoffice, or use Java, or ...?)  I have MS Office installed which may be affecting the choice made by the program. What do you have?
>>>
>>
>>
>> Just curious, what output do you get if you request all of the output arguments?  Please try:
>>
>> >>  [num_array, text_array, raw_array, limits] = xlsread('test.xlsx')
>>
>>
>>
>

Copying the list. At this point I'm not sure what else to do. You could try stepping through the xlsread mcode and see if anything jumps out.

Might want to file a bug report at bugs.octave.org to get developer eyes on the problem...


reply via email to

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