Find out data present in cell based on data present in adjacent cell

Hi All,
I Want to find out the data present in the cell, based on data present in other cells. Below is an example.
FA1

In this excel file, I want to find out data present in column C based on data present in column B and column A. For example. If emailID is “123@rediffmail.com” and Company is “Rediff” then it should return me representative column’s value “Re4”. If EMailID is xyz@hotmail.com and company is TCS, it should return me value “Re2” from the Representative column.

Thanks.

Hi @sandyk

Assume that this information in a datatable called DT

You have write this query
DT.Select("[EmailId]=‘123@rediffmail.com’ And [Company]= ‘Rediff’ ")(0)(“Representative”).ToString

This will Give you desired output

Regards
Roshan

Please mark as solution if found helpful :slight_smile:

Another way to do this would be to loop through the Data table using a for each row method.

The assign reads Representative = row("Representative").ToString

Thanks Bro! It was helpful.

Thanks Anupam. It was very helpful :slight_smile:

1 Like

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