Using Excel functions to return a value within a range

Tyril_Simmons

New Member
Joined
Apr 17, 2002
Messages
2
I'm trying to use Excel built in functions to return the first value after the #N/A within my range of data. The data appears in column A1:A24 as shown below:

2
#N/A
3
4
5
6
7
#N/A
#N/A
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22

The function should return the value 3.

Any one with any ideas?
 

Excel Facts

What is the shortcut key for Format Selection?
Ctrl+1 (the number one) will open the Format dialog for whatever is selected.
On 2002-04-18 08:13, Tyril_Simmons wrote:
I'm trying to use Excel built in functions to return the first value after the #N/A within my range of data. The data appears in column A1:A24 as shown below:

2
#N/A
3
4
5
6
7
#N/A
#N/A
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22

The function should return the value 3.

Any one with any ideas?

Array-enter:

=INDEX(A1:A24,MATCH(TRUE,ISNA(A1:A24),0)+1)

In order to array-enter a formula hit control+ahift+enter at the same time, not just enter.
 
Upvote 0
That function handles cases where there is only one #N/A. How about with multiple #N/A one after the other. For example if my range chages to A2:A24 I would like the function to return the value 8.
 
Upvote 0
On 2002-04-18 08:34, Tyril_Simmons wrote:
That function handles cases where there is only one #N/A. How about with multiple #N/A one after the other. For example if my range chages to A2:A24 I would like the function to return the value 8.

Right.

Array-enter:

=INDEX(A1:A24,MATCH(MATCH(TRUE,ISNA(A1:A24),0),ISNUMBER(A1:A24)*ROW(A1:A24))+1)

In order to test the formula, just change the location of the first #N/A, not the range.

BTW, if the range changes frequently, we can create dynamic name range that you can use in this and other formulas.

Aladin
 
Upvote 0

Forum statistics

Threads
1,214,819
Messages
6,121,739
Members
449,050
Latest member
excelknuckles

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