MATLAB Answers

xlwrite problem - Undefined function or variable 'XSSFWorkbook'

14 views (last 30 days)
James Russell
James Russell on 15 Jul 2015
Commented: Osman Ciftci on 30 Jan 2019
Matlab's xlswrite does not work in OSX. Instead, I have tried xlwrite, a Java-based solution to the same need contributed to File Exchange by Marin Deresco. After getting the associated Java "Poi" library onto my Java path, I get "Undefined function or variable 'XSSFWorkbook'. Error in xlwrite (line 148)" when I run the associated Text_xlWrite.
Anyone know how to get xlwrite to work on OSX? An alternative substitute to xlswrite would also be welcome.
OSX 10.10.4, Matlab (R2015a)


Show 1 older comment
Marshall on 7 Aug 2015
The most common reason for this is that the jar files in the poi-library are not in the Matlab path; make sure you have the poi-library added to your path.
I sometimes still receive this error the first time I run xlwrite(), but it disappoints on subsequent calls.
Walter Roberson
Walter Roberson on 7 Aug 2015
xlswrite() does work on OS-X, provided you restrict yourself to "basic" mode.
Osman Ciftci
Osman Ciftci on 30 Jan 2019
@Walter Roberson,
the xlswrite doesn't have the basic mode in some versions, such as 2017b. (Link to the documentation on Mathworks website: )
What would you propose?
Thnx in advance :)

Sign in to comment.

Answers (0)

Community Treasure Hunt

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

Start Hunting!

Translated by