Excel Task help

9 Critical illness.xlsx (7.8 KB)

Hello guys,

I need some help for one task. following is my excel sheet in tat i want to take data from cell based on headers i.e. kind of we lookup i want to take a cell value(8.93) from excel sheet. it should check Age Band/Tenure (age as 36-40) and upper header as 3. how can i do it can anyone help me out in this…

Thanks in advance

1 Like

Hi @Rahul_Jawahirani

If you have the values for Age Band and Tenure you can apply the following logic:

  1. Read your excel file and save it in a variable vDataTable
  2. Use a linq expression to get the row with the desired value vDataTable.AsEnumerable().Where(function® r.item(“Age Band/Tenure”).Equals(Age Band)).First().Item(Tenure)

Be careful, if your combination of Age Band and Tenure doesn’t exist is going to throw you an error.

Hie @AndresTarazona ,

Thanks for your reply im getting an error. Can you plz share your workflow…

Sequence1.xaml (6.0 KB)

1 Like

Be careful, do not change the dash that separate the age range, also, do not include spaces, if you need to do it, update the code accordingly.

Regards,

Andres

Thanks alot @AndresTarazona,

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