ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Worksheet Functions (https://www.excelbanter.com/excel-worksheet-functions/)
-   -   Refer to a Single cell in a name range (https://www.excelbanter.com/excel-worksheet-functions/114968-refer-single-cell-name-range.html)

Jitendra Kumar

Refer to a Single cell in a name range
 
Is anyone there who can help me out?

What is the formula needed to refer a single cell in a named range of cells.
I mean, I want to compare a cells value with any of the cell values in the
named range. let the named range be "holidays"

vezerid

Refer to a Single cell in a name range
 
To identify a specific cell in a range, say the 5th cell in there you
use INDEX:

=INDEX(holidays, 5)

To see if a cell's value appears in holidays you use MATCH:

=MATCH(A2, holidays, 0)

This returns the position of A2 value in holidays. If the value of A2
is not found in holidays this returns the #N/A error. If you want to
test if the value appears in holidays you check if MATCH returns a
number:

=IF(ISNUMBER(MATCH(A2, holidays, 0))," In set", "Not in set")

HTH
Kostis Vezerides


Jitendra Kumar wrote:
Is anyone there who can help me out?

What is the formula needed to refer a single cell in a named range of cells.
I mean, I want to compare a cells value with any of the cell values in the
named range. let the named range be "holidays"




All times are GMT +1. The time now is 07:18 AM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
ExcelBanter.com