2

I have the following simple document where I want to access an ODS spreadsheet.

\documentclass[]{report}
\usepackage{odsfile}

% Title Page
\title{odsfile Test}
\author{}


\begin{document}
\maketitle

\begin{tabular}{lr}
\includespread{file=simpleodsfile.ods}
\end{tabular}


\end{document}         `

But the compile fails with the following error message:

lualatex --shell-escape odsfile_test.tex
This is LuaTeX, Version beta-0.80.0 (TeX Live 2015/Arch Linux) (rev 5238) 
 \write18 enabled.
(./odsfile_test.tex
LaTeX2e <2015/10/01> patch level 2
Babel <3.9m> and hyphenation patterns for 79 languages loaded.
(/usr/share/texmf-dist/tex/latex/base/report.cls
Document Class: report 2014/09/29 v1.4h Standard LaTeX document class
(/usr/share/texmf-dist/tex/latex/base/size10.clo))
(/usr/share/texmf-dist/tex/lualatex/odsfile/odsfile.sty
(/usr/share/texmf-dist/tex/lualatex/luacode/luacode.sty
(/usr/share/texmf-dist/tex/generic/oberdiek/ifluatex.sty)
(/usr/share/texmf-dist/tex/luatex/luatexbase/luatexbase.sty
(/usr/share/texmf-dist/tex/luatex/ctablestack/ctablestack.sty)))
(/usr/share/texmf-dist/tex/latex/xkeyval/xkeyval.sty
(/usr/share/texmf-dist/tex/generic/xkeyval/xkeyval.tex
(/usr/share/texmf-dist/tex/generic/xkeyval/xkvutils.tex
(/usr/share/texmf-dist/tex/generic/xkeyval/keyval.tex))))) (./odsfile_test.aux)
[1{/var/lib/texmf/fonts/map/pdftex/updmap/pdftex.map}]
! LuaTeX error /usr/share/texmf-dist/tex/lualatex/odsfile/odsfile.lua:71: attemp
t to index local 'x' (a nil value)
stack traceback:
        /usr/share/texmf-dist/tex/lualatex/odsfile/odsfile.lua:71: in function 'getTabl
e0'
        /usr/share/texmf-dist/tex/lualatex/odsfile/odsfile.lua:26: in function 'getTabl
e'
        [\directlua]:1: in main chunk.
\luacode@dbg@exec ...code@maybe@printdbg {#1} #1 }

l.13 \includespread{
                  file=simpleodsfile.ods
? quit()
OK, entering \batchmode[peter@rohan groupprojectaudit]

I don't believe my ods file (Libreoffice 5.1.3) to be the problem, as it is just a example with two column headers and two rows with numbers. Edit: I also tried to specify the full path name of my file, but with the same results, again with the same error in line 71 of odsfile.lua

0

1 Answer 1

1

The \includespread uses [] braces instead of {} for the keyval arguments:

\documentclass[]{report}
\usepackage{odsfile}

% Title Page
\title{odsfile Test}
\author{}


\begin{document}
\maketitle

\begin{tabular}{lr}
\includespread[file=simpleodsfile.ods]
\end{tabular}


\end{document}   

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .