[Advanced Excel] [Advanced Excel] worksheet position out of range.
Forge component by Carlos Freitas
Application Type

I have .xls file. I want to chage the startindex of file from 1 to 7.

1. When I am deleting all the 1-6 rows (Entity headers are at first position then it is reading a data).

2.My excel sheet headers are at row 7. I want to read/write a data from 8th row in .xls file.

I have used advanced excel ... 

WorkBook_Open (Binarydata file input parameter) -> WorkBook_changesheetindex (

Workbook_Open.Workbook,CurrentIndex - 1 , NewIndex - 7


 after this i gave ExceltoRecordList.

But it is giving me "Worksheet position out of range." Error.

In Simple words I have .xls file and I want to read data, 7th Row are header and data start from 8th Row.

Thank you

Hello Abhijeet,

If possible, please share a screenshot of the action and its logic to make sure you are not missing any steps in the creation/ update of the workbook and opening of the workbook.



Thank You AJ for reply,

Sorry I am not allowed to share any screenshots, Hope you understand.

If possible just let me know the solution to read data from .xls file, 7th Row are header (Not at Row 1 ) and data start from 8th Row.

Thank you. 

Hello @Abhijeet Joshi,

You are encountering the 'worksheet position out of range' error because you are attempting to change the worksheet's index and not the Row index. Please review the attached oml. 

The steps I took are: 1) Open workbook 2) Get the first worksheet's dimensions 3) Delete desired # of rows from the top and 4) Create/download the new workbook.

In the oml, I have imported an excel file 'Country' into the Data -> Resources. Here is the before and after.

Hope this solves it,




Sorry I was busy so not able to reply.

For Country.xlsx file it is working fine.

But for my file is not .xlsx it is .xls (Microsoft Excel 97-2003 worksheet )

Please let me know if it is working for .xls file format?

Hello Abhijeet,

My mistake, I did miss the fact that you clearly mentioned '.xls' as the file type you are working with. 

Given that, unfortunately the error you are encountering is expected because the Advanced Excel component is designed to work with only '.xlsx' file types. This is confirmed by the details available on the forge component page outsystems.com/forge/component-overview/355/advanced-excel.

The component uses EPPlus and the information available at https://epplus.codeplex.com confirms the following:

Hope this helps,



Community GuidelinesBe kind and respectful, give credit to the original source of content, and search for duplicates before posting.