Scilab Function
Last update : 23/10/2007

xls_read - read a sheet in an Excel file

Calling Sequence

[Value,TextInd] = xls_read(fd,Sheetpos)

Parameters

Description

This function reads an Excel sheet given a logical unit on an Excel stream ant the position of the beginning of the sheet within this stream. It returns the numerical data and the strings contained by the Excel cells.

The readxls function can be used to read all an Excel file in one function with a single function call.

Warning only BIFF8 Excel files (last Excel file version) are handled

Examples

   //Decode ole file, extract and open Excel stream
    [fd,SST,Sheetnames,Sheetpos] = xls_open('SCI/demos/excel/Test1.xls')
    //Read first data sheet
    [Value,TextInd] = xls_read(fd,Sheetpos(1))
    //close the excel stream
    mclose(fd)
  

See Also

xls_open ,   readxls ,  

Authors

Pierrick Mode INRIA
Serge Steer INRIA

Bibliography

This function is based on Excel stream description from OpenOffice (http://sc.openoffice.org/excelfileformat.pdf).

Used Function

This unction uses the xls.c file which can be found in a Scilab source version in the directory SCIDIR/routines/sound