find the first cell in a row that is >=0

MartinL

Well-known Member
Joined
Oct 16, 2008
Messages
1,141
Office Version
  1. 365
Platform
  1. Windows
I am trying to find the cell in a row that is >= 0%

[TABLE="class: grid, width: 500"]
<tbody>[TR]
[TD]Jan[/TD]
[TD]Feb[/TD]
[TD]Mar[/TD]
[TD]Apr[/TD]
[TD]May[/TD]
[TD]Jun[/TD]
[TD]Jul[/TD]
[TD]Aug[/TD]
[TD]Sep[/TD]
[TD]Oct[/TD]
[TD]Nov[/TD]
[TD]Dec[/TD]
[/TR]
[TR]
[TD]-0.3%[/TD]
[TD]-0.2%[/TD]
[TD]-0.1%[/TD]
[TD]0.1[/TD]
[TD]0.2[/TD]
[TD]0.3[/TD]
[TD]0.4[/TD]
[TD]0.2[/TD]
[TD]0.5[/TD]
[TD]0.1[/TD]
[TD]0.15[/TD]
[TD]0.1[/TD]
[/TR]
</tbody>[/TABLE]

In the table above i need to return Apr as the first month where the percentage is >= 0
 

Excel Facts

Last used cell?
Press Ctrl+End to move to what Excel thinks is the last used cell.
How about

Excel 2013/2016
ABCDEFGHIJKLM
1JanFebMarAprMayJunJulAugSepOctNovDec
2-0.30%-0.20%-0.10%0.10.20.30.40.20.50.10.150.1Apr
Raw Data
Cell Formulas
RangeFormula
M2=INDEX(A1:L1,MATCH(TRUE,INDEX(A2:L2>0,0),0))
 
Upvote 0
=INDEX(A1:L1,MATCH(TRUE,INDEX(A2:L2>0,0),0))

Hi steve the fish/Fluff

I did this and it works...
as expected it opened a can of worms but it works exactly as I needed many thanks

the can of worms is an issue when if there are no values >0
So I just need to get something like IFERROR(INDEX(A1:L1,MATCH(TRUE,INDEX(A2:L2>0,0),0)),"Not Found")
Which will return some text if there are no values >0
 
Last edited:
Upvote 0
What happens when you try that formula?
 
Upvote 0

Forum statistics

Threads
1,223,886
Messages
6,175,196
Members
452,616
Latest member
intern444

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