Find first non-zero numeric value in a row

derekbez

New Member
Joined
Oct 21, 2009
Messages
3
Hi,
First post, but irregular visitor - thanks for previous help!

I have someone else's spreadsheet that tries to simulate a sort of gantt chart. However, it doesn't explicitly give the key dates of events, so I'd like to extract them into a column.

Imagine the sheet has dates in a row b3:bz3.
a4:a300 has a list of locations.
The 'content' b4:bz300 is populated by formulas and can be: zero, blank, text or numeric.

So for example, the row for location 'New York' could have:
{0,0,0,0,0,0,0,0, ,0,0,0,text,0,text,0,0,12,400,400,0,0,0,0,text,.....}

I'm only interested the column the first non-zero number appears in. In the example, this would be "12", in the 18th col.

The formula I have so far:
=INDEX($B$3:$BZ$300,1,MATCH(TRUE,INDEX($B4:$BZ4>0,0,0),0))

I think it's close... but it is returning the first text cell, not the first numeric one.

Any suggestions?

As said, this is someone else's (protected) spreadsheet which is updated every couple of weeks. I need to extract this date data for my part of the project, but I'll probably try encourage the owner to include the column in future.

Thanks in advance.
 

Some videos you may like

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)

Watch MrExcel Video

Forum statistics

Threads
1,127,590
Messages
5,625,674
Members
416,125
Latest member
NeedExcelHelp2021

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
Top