Error reading an XLSX file

Hello everybody

I’m having trouble reading the fields from my XLSX file, when I try this error message appears: MethodError: no method matching iterate(::XLSX.DataTable)

using DataFrames, XLSX

r = string(@__DIR__,"\\teste.xlsx"); XLSX.readxlsx(r)
raquel = DataFrame(XLSX.readtable(r, "raquel")...) MethodError: no method matching iterate(::XLSX.DataTable)

XLSXFile(“teste.xlsx”) containing 3 Worksheets

               raquel 4x1           A1:A4        
               andrea 4x1           A1:A4        
               arthur 4x1           A1:A4 

You are using outdated syntax, see:

https://felipenoris.github.io/XLSX.jl/stable/migration/

or the docstring:

help?> XLSX.readtable()
  readtable(
      filepath,
      sheet,
      [columns];
      [first_row],
      [column_labels],
      [header],
      [infer_eltypes],
      [stop_in_empty_row],
      [stop_in_row_function]
  ) -> DataTable

  Returns tabular data from a spreadsheet as a struct XLSX.DataTable. Use this function to create a DataFrame from package DataFrames.jl.

(...)

Example
  ≡≡≡≡≡≡≡≡≡

  julia> using DataFrames, XLSX

  julia> df = DataFrame(XLSX.readtable("myfile.xlsx", "mysheet"))
1 Like

Thanks!!