Error Reading Cell: Index was out of range


I am facing a problem when reading a simple cell from an excel.

I’m using the Read Cell Activity from “System, File, Workbook” (I must use this activity). The problem is that the activity actually works with some excel files, but does not work with other excel files. I checked the type of the cell and they are the same and are located in the same cell position and the sheetnames are the same and even I copied the content from the ‘working ones’ and the result is the same.

The error that is throwing me is the following:


And as I said, with some excel files it perfectly works but with others nope.

I dont even understand that error message.

If you guys could help me, I will appreciate it very much.

1 Like

The problem is with your range only. What you have provided on range?

This activity does not use range because it is a Read Cell. In the cell field I provide the cell “K16”.


1 Like

Is the sheet name correct? Is there any extra spaces?

Please check your input excel file contains value in k16 cell or not . Seems like you are trying to read data which doesn’t exist.

Thank you for your responses but I double checked that the sheetname is correct and that also there is information in the cell.

Some of my mates have had the same issue and have not found a solution yet.

1 Like

Can you try Excel application scope with Excel read cell instead of workbook read cell?

I already tried with Excel App Scope and actually it works, but the reason that I am using the other one is that when I use Read cell from Excel App scope, in some files shows up a window asking for update links for the content.

I tried to hide this window changing some configurations but I’ve been unsuccesfully so far.

1 Like

Usually when you get an “Index was out of range” error it means that you have some list, array, or datatable which you are trying to use an index that is bigger than the items in the list. The error might not be coming from the Read Cell, but another activity where you use a list or datatable. But, I could be wrong.

1 Like

Yeah, I thought the same, but I think in this case it can not be possible because Im doing unitary tests, I mean I only have this activity in a test sequence. :frowning:

I see it does say Source: Read cell.
Workbook activities do have issues sometimes, like if the file is opened they can’t be used at all, which is why I use Excel Scopes (possibly with “Visible” unchecked) to read data. I wonder if the Workbook Read Cell is not seeing any data in column K, so when you try to Read the cell, it can only see in specific columns which it sees data in.

1 Like

Yeah I tried checking and unchecking the different parameters
Why should this happen? Why should uipath be available to see just some sort of columns? Anyway i didn’t find a solution yet, I had to implement a workaround using clicks and hotkeys :sleepy:

1 Like

It’s definitely bug in read range workbook activity. Because it’s using parsing xml documents under the hood. Probably your excel files contain some problems. I think you have to fill the bug to Uipath. And use read range excel scope activity instead of. You can suppress update links message in excel.

1 Like

Can we have that excel file?

I encountered this when I convert .XLS file to .XLSX.

Hi @Emman_Pelayo

Could you prepare a sample project with a sample Excel that reproduces the issue? Also, please let us know the Studio version and the Excel activity package version.

Hi @loginerror

I am facing a similar issue as @davidquezada.
Studio version: 2018.4.3
UiPath.Excel.Activities: 2.4.6884.25683
Activity used: UiPathExcel.Activities.ReadColumn
Error message: Index was outside the bounds of the array

As my account is new, I do not have the right to upload files. Would really appreciate your help if I could get in touch with you via other channels so that i can send you test file.


Hi @mingjun.tan

Welcome to our UiPath Forum :slight_smile:

You can easily get the permission to post an image by reaching Trust Level 1 (it really only takes a small moment):

The best way would be if you could provide a sample project that reproduces the issue. Just create a new project, add minimum amount of activities that will cause this error and then zip the entire project and attach it here. If you will still struggle with Forum permissions, just use one of the file storage sites to generate a link (Google Drive, etc). :slight_smile:

Thanks a bunch! I have attached a new project (1 activity only), along with the offending excel sheet in the following link:

Really appreciate your prompt response haha

1 Like


It would seem like this is a workaround:
(basically using the Excel Application Scope instead of the Workbook activities.

I will submit it as a bug for our team to have a look. It would seem that workbook activity does not handle complicated Excels.