How do I fix rexllent package error: Failed to convert to string

Hi,

I am very new to typst and enjoying it very much. I have searched for this issue, however, I have not found any similar problem discussed elsewhere.

I am trying to import a simple table from an Excel file following the instructions on the rexllent package site.

#xlsx-parser(read("file - name.xlsx"), encoding: none, sheet-name: "Sheet2")

The function returns error failed to convert to string (file is not valid UTF-8 in @ws/p0:0.0.0.0/file - name.xlsx:1:1

As far as I know Excel can only save CSVs in UTF-8, not in XSLX format which rexllent expects. I would be grateful for any pointers to documentation or hints about how to solve this.

Thank you!

Hi, welcome to the forum!

encoding is an option of read, not xlsx-parser. So try this:

#xlsx-parser(read("file - name.xlsx", encoding: none), sheet-name: "Sheet2")
1 Like