If Function with Strucutred References

David199

New Member
Joined
Apr 14, 2017
Messages
6
I'm trying to create a simple table to be referenced by an IF function.

I want to create a single column table of hotel names (i.e. Marriott, Doubletree, etc) and then write an excel formula that says IF(cell reference=a name in the table,"HOTEL","").

In other words, I would like my logical test for the IF function to have many correct outcomes, not just one. I want the IF function to search for an match in the entire table, not a single cell. Is that possible?
 

Excel Facts

Spell Check in Excel
Press F7 to start spell check in Excel. Be careful, by default, Excel does not check Capitalized Werds (whoops)
Hi,

Use COUNTIF

If you need help setting the formula, please give more description of what you want the formula to do, and what results you want.
 
Upvote 0
It sounds like you are doing something like this:


Excel 2010
ABCD
1Hotel Names
2MarriotDoubletreeHOTEL
3DoubletreeNot a hotel 
4Motel 6
Sheet1
Cell Formulas
RangeFormula
D2=IF(COUNTIF(A:A,C2),"HOTEL","")
D3=IF(COUNTIF(A:A,C3),"HOTEL","")
 
Upvote 0

Forum statistics

Threads
1,214,952
Messages
6,122,454
Members
449,083
Latest member
Ava19

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