xlsread - Undefined function 'dec2base27

Hi I am running R2013a on Windows 7 Prof. I have been successfully using xlsread in a script to read .xlsx spreadsheets (Excel 2010) - worked 100%. Last night I accidentally opened another instance of Matlab, my pc slowed down dramatically, but the script was still executing. I then closed both instances of Matlab and opened only one instance. Since then I have been getting this error: Undefined function 'dec2base27' for input arguments of type 'double'. Searches via Google show quite a few similar problems. I have tried the following (without success): (I used the function as follows: [~,~,RAW]=xlsread(FILE,SHEET,RANGE)) a] Have relevant spreadsheet open/closed will running the script. b] Removing the 'Range' argument. c] Added the 'basic' argument. d] Changing spreadsheet to Excel 97 format. e] Disabling Excel add-ins: - Send to Bluetooth" (btsendto_office.dll) - I do not have this add-in: ADTAPLib.ApproveItAddin
Please advise Thanks Andre

3 Kommentare

Jan
Jan am 12 Okt. 2016
Please copy the complete error message. Most of all the failing line matters.
MEBARA TANGA Serge
MEBARA TANGA Serge am 13 Nov. 2016
Bearbeitet: MEBARA TANGA Serge am 13 Nov. 2016
Hi @ Jan Simon,
i have the same problem. I think it is like you can see in this pic. For me, when i use xlsread on other laptop it doesnt work. But in mine it works well. I developed my app with my laptop.
PS:Sorry for my English, i am French. My matlab version :8.2.0.701 (R2013b)
thanks
Jan
Jan am 13 Nov. 2016
@MEBARA TANGA Serge: Please post the message as text, not as screen shot. It is much easier to ask an internet search engine for details, when I can use copy&paste, instead of typing the text by my own.

Melden Sie sich an, um zu kommentieren.

Antworten (3)

Walter Roberson
Walter Roberson am 13 Nov. 2016

1 Stimme

In R2013b, dec2base27 was a function inside of xlswrite.m and xlsread.m did not use dec2base27 at all.
You should be checking for the possibility that you are using an old version of xlsread.m . In R2013b, line 105 of xlsread.m should say
% $Revision: 1.23.4.43 $ $Date: 2012/12/10 23:52:43 $
Pritesh Shah
Pritesh Shah am 12 Okt. 2016

0 Stimmen

Dear Andre,
Restart the laptop. It may work.. :))

1 Kommentar

MEBARA TANGA Serge
MEBARA TANGA Serge am 13 Nov. 2016
Hi, I have the same problem. I have already restart the laptop but it doesnt work.
Can you help me?

Melden Sie sich an, um zu kommentieren.

Jen
Jen am 31 Jan. 2017

0 Stimmen

Hi, I have the same problem. The error message is:
Error using xlsread (line 248)
Undefined function 'dec2base27' for input arguments of type 'double'.
Line 105 of xlsread.m says exactly:
% $Revision: 1.23.4.43 $ $Date: 2012/12/10 23:52:43 $
Thank you for your answer!

6 Kommentare

It is a mystery to me. xlsread() did change in R2013b compared to several releases before, but the changes had nothing to do with dec2base27 . The only call to dec2base27 in all of MATLAB and all the toolboxes I have was in xlswrite(), which is not invoked from xlsread() -- not unless one of the comments somehow got uncommented.
I think you will need to step through an invocation of xlsread to see how the dec2base27 routine is getting called.
Or a perhaps shorter way would be to create your own
function dec2base27(varargin)
keyboard
and then run and when it stops waiting for keyboard input, use dbstack to see where it was called from.
Jen
Jen am 1 Feb. 2017
Bearbeitet: Jen am 1 Feb. 2017
Hi Walter, thank you very much for your help!
The function dec2base27 is used in xlsreadCOM.m which is called on line 232 of xlsread.m.
When I try to debug the function dec2base27, MATLAB says : "File C:\MATLAB\V_R2013b\soft\toolbox\matlab\iofun\private\dec2base27.m is not found in the current folder or on the MATLAB path."
The function dec2base27 is exactly on that folder : C:\MATLAB\V_R2013b\soft\toolbox\matlab\iofun\private but it seems that MATLAB couldn't recognize it.
Any idea? If there is something else to do with MATLAB so that it recognizes the function?
Thank you for your help!
Walter Roberson
Walter Roberson am 1 Feb. 2017
I checked in R2013b on Windows; xlsreadCOM.m does not call dec2base27 in any obvious way. I wonder if you could track down more exactly which line in xlsreadCOM calls it?
C:\Program Files\MATLAB\R2013b\toolbox\matlab\iofun\private does not contain dec2base27
I am searching all of my downloaded past versions again to see if I can find evidence of it existing as a file in a previous version; I did not find it when I looked at my installed versions yesterday.
Walter Roberson
Walter Roberson am 1 Feb. 2017
dec2base27 was in the iofun/private directory only in R2015a, R2015b, and R2016a (but not R2016b). It was not used in xlsreadCOM in R2013b; the xlsreadCOM routine in R2013b has no version number but is marked "Copyright 1984-2013"; the version that uses dec2base27 is marked "Copyright 1984-2014".
Please check the copyright dates in the C:\MATLAB\V_R2013b\soft\toolbox\matlab\iofun\private\xlsreadCOM.m that you see, as I suspect that somehow you managed to get an newer version merged in with that version.
Jen
Jen am 2 Feb. 2017
Yes, it seems that I have a newer version of xlsreadCOM :
% Copyright 1984-2015 The MathWorks, Inc.
Walter Roberson
Walter Roberson am 2 Feb. 2017
A 2015 copyright certainly should not have been present in R2013b. You might need to reinstall MATLAB to get the correct version.
Had you installed a Mathworks patch at some point?

Melden Sie sich an, um zu kommentieren.

Kategorien

Tags

Gefragt:

am 12 Okt. 2016

Kommentiert:

am 2 Feb. 2017

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by