Extracting Data From Excel

I have the below data file that is received each day and I need to extract the value shown in yellow. This is usually in cell F21, but sometimes the location can vary.

What would be the best method for extracting this data?

Thanks in advance.

Hi @Gavin_Mcmaster,
assume that you read this sheet and output of read range is stored in “dt” variable.

assign this to a variable,

dt.asenumerable.where(function(x) x("Interactive Brokers").toString.trim = "Intrest Accurals")(0).item(4).toString

1 Like

That looks confusing. :slight_smile:

Can you please explain what the code does / how it works?

I assume it tells the robot to go down from “Interactive Brokers” until it finds “Interest Accruals” and then returns the 4th item along?

Thanks.

“interest accruals” - spelling mistake

Yes, your correct

1 Like

Fantastic! Thanks. Last question. My file name will change each day to reflect the new date, I tried using the wildcard * in the file path but it wouldn’t work. Any ideas how to solve that?

Capture

Use,
Date. Now. ToString (“yyyyMMdd”) will return 20190311

Hope you will need something like this

This topic was automatically closed 3 days after the last reply. New replies are no longer allowed.