Lookup type search to return text value

ronie85

Board Regular
Joined
Jan 25, 2014
Messages
89
Office Version
  1. 365
Platform
  1. Windows
Hi, Hopefully someone can help.

I require a formula in Sheet 1, A1 to search for text contained within Sheet 1, A2. The formula will need to see if the text appears in Sheet 2, C1 to C999 for which it will return the text "NI", or Sheet 3, C1 to C999 for which it will return the text "ROI". Please note that the text it is searching will only appear in one sheet so it will always return a correct value.
 

Excel Facts

Best way to learn Power Query?
Read M is for (Data) Monkey book by Ken Puls and Miguel Escobar. It is the complete guide to Power Query.
Hi Welcome to the forum.

Would this do the trick for you ?

Excel Formula:
=IF(XLOOKUP(A2,Sheet2!C1:C999,Sheet2!C1:C999,"")=A2,"NI",IF(XLOOKUP(A2,Sheet3!C1:C999,Sheet3!C1:C999,"")=A2,"ROI"))
 
Upvote 0
Glad to help. thanks for the feedback.
Rob
 
Upvote 0

Forum statistics

Threads
1,213,504
Messages
6,114,020
Members
448,543
Latest member
MartinLarkin

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top