Error using xlsread 'No appropriate method, property, ...'

Hi,
I have MATLAB R2015a and i want to read out a xls excel sheet with matlab. Every time I open it in my code i get this red Error:
_Error using xlsread (line 247)
No appropriate method, property, or field 'FileFormat' for class
'Interface.000208DA_0000_0000_C000_000000000046'._
I already created my own excel sheet but i receive the same error.
Yesterday everything worked fine. Don't why it stucks today.

10 件のコメント

KSSV
KSSV 2016 年 8 月 25 日
Have you checked this with different xl files?
Walter Roberson
Walter Roberson 2016 年 8 月 25 日
Which operating system are you using?
I suspect you are going to need to command
dbstop if caught error
and run the xlsread again, and see where it ends up stopping. It might possibly be within xlsinfo
Christoph Thale
Christoph Thale 2016 年 8 月 25 日
I checked it with different xl files. Every time the same error.
What is 'operating system' ?
The error is the xlsread(..)
[num,txt,Messwerte{i}] = xlsread(Pfad,3);
Perhabs there is trouble with the loop. I dont know
Walter Roberson
Walter Roberson 2016 年 8 月 25 日
Are you using MS Windows, Linux, or OS-X ?
Walter Roberson
Walter Roberson 2016 年 8 月 25 日
The error is the xlsread(..)
No it is not. The error is being reported inside xlsread(), and the line number given there (247) is where xlsread() handles exceptions that have occurred in the code that it is calling. The actual error is in one of the routines that xlsread() is calling but at the moment we do not know which. If you give that command
dbstop if caught error
and run the program, then it will stop at some lower level routine that was called from xlsread where the error is being generated.
Guillaume
Guillaume 2016 年 8 月 25 日
編集済み: Guillaume 2016 年 8 月 25 日
Interface.000208DA_0000_0000_C000_000000000046 is the _Workbook interface, which definitively has a FileFormat property.
Therefore, it is very puzzling that you get this error.
What happens when you open the same file directly in Excel?
Note that since you do have a workbook object, matlab managed to open the file.
Also, what is the extension of the file?
Christoph Thale
Christoph Thale 2016 年 8 月 26 日
Well, there are some Makros in the Excel-Map I am reading out. I cannot access them because they are password secured.
Noteworthy is, when I am runnig another MATLAB script which is reading out some 'normal' excel sheets before the one that is linked to the 'weird-makro-excel-map' , there will pop up no error message. I dont know what happend in the background with the sync. between Excel - Matlab.
Guillaume
Guillaume 2016 年 8 月 26 日
If you can attach the offending file (assuming it's not confidential) we could try to analyse what is happening.
If the information is confidential, you could replace it with dummy data. I doubt the actual content of the sheet matters for this problem.
Christoph Thale
Christoph Thale 2016 年 8 月 26 日
It is not able to look in the Makro-Code without the password.
Guillaume
Guillaume 2016 年 8 月 26 日
If the file is in xls format, the password protection is easy to bypass/remove. What I want to look at is the file structure, so the fact that the macros are password protected shouldn't matter.

サインインしてコメントする。

回答 (1 件)

KSSV
KSSV 2016 年 8 月 25 日

0 投票

I guess problem is with loop... Instead of [num,txt,Messwerte{i}] = xlsread(Pfad,3); use as below
[num,txt,Messwerte1] = xlsread(Pfad,3);
Messwerte{i} = Messwerte1 ;

1 件のコメント

Guillaume
Guillaume 2016 年 8 月 25 日
The two different syntaxes are equally valid and will make absolutely no difference to what happens.
This certainly won't resolve any problem.

サインインしてコメントする。

質問済み:

2016 年 8 月 25 日

コメント済み:

2016 年 8 月 26 日

Community Treasure Hunt

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

Start Hunting!

Translated by