Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 65
Default find first positive number in column

I have a column of figures, maximum of 7 numbers in total and need to find
the first positive number in the column, negatives will always be shown first
and are dependant on other calculations. Some of the last cells may be blank
depending on the periods in the term ie
1. -10
2. -1
3. 10
4. 5
5. 80
6.
7.
Should return 10 as the first positive in the list
Is there a built in fucnction I can use to do this? Many thanks for any help

Sheila D

  #2   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 35,218
Default find first positive number in column

=INDEX(A1:A10,MATCH(TRUE,A1:A100,0))

This is an array formula. Hit ctrl-shift-enter instead of enter. If you do it
correctly, excel will wrap curly brackets {} around your formula. (don't type
them yourself.)

Adjust the range to match--but you can only use the whole column in xl2007.

Sheila D wrote:

I have a column of figures, maximum of 7 numbers in total and need to find
the first positive number in the column, negatives will always be shown first
and are dependant on other calculations. Some of the last cells may be blank
depending on the periods in the term ie
1. -10
2. -1
3. 10
4. 5
5. 80
6.
7.
Should return 10 as the first positive in the list
Is there a built in fucnction I can use to do this? Many thanks for any help

Sheila D


--

Dave Peterson
  #4   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 11,058
Default find first positive number in column

For column A:

=INDEX(A:A, MATCH(TRUE, (A1:A10)0,0))

must be entered as an array formula with CNTRL-SHFT-ENTER rather than just
the ENTER key.
--
Gary''s Student - gsnu200799
  #5   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 65
Default find first positive number in column

Thank you very much

"Sheila D" wrote:

I have a column of figures, maximum of 7 numbers in total and need to find
the first positive number in the column, negatives will always be shown first
and are dependant on other calculations. Some of the last cells may be blank
depending on the periods in the term ie
1. -10
2. -1
3. 10
4. 5
5. 80
6.
7.
Should return 10 as the first positive in the list
Is there a built in fucnction I can use to do this? Many thanks for any help

Sheila D



  #6   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 65
Default find first positive number in column

Hi agfin and thanks for previous help
As a follow on from that once I have found the first positive value I need
to output that and then all following values in sequence ie from
1. -10
2. -1
3. 10
4. 5
5. 80
6.
7.

10 then 5 then 80
Is there a way to specify the next record(s) where value is present.

Sheila

"Sheila D" wrote:

I have a column of figures, maximum of 7 numbers in total and need to find
the first positive number in the column, negatives will always be shown first
and are dependant on other calculations. Some of the last cells may be blank
depending on the periods in the term ie
1. -10
2. -1
3. 10
4. 5
5. 80
6.
7.
Should return 10 as the first positive in the list
Is there a built in fucnction I can use to do this? Many thanks for any help

Sheila D

  #7   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 5,651
Default find first positive number in column

On Mon, 11 Aug 2008 05:50:00 -0700, Sheila D
wrote:

Hi agfin and thanks for previous help
As a follow on from that once I have found the first positive value I need
to output that and then all following values in sequence ie from
1. -10
2. -1
3. 10
4. 5
5. 80
6.
7.

10 then 5 then 80
Is there a way to specify the next record(s) where value is present.

Sheila


Assuming your data is in A1:A7

Enter this formula in some cell, then fill down seven rows:

=IF(INDEX($A$1:$A$7,ROWS($1:1)-1+MATCH(TRUE,$A$1:$A$70,0))0,
INDEX($A$1:$A$7,ROWS($1:1)-1+MATCH(TRUE,$A$1:$A$70,0)),"")

As before, this is an **array** formula to be entered with
<ctrl<shift<enter.
--ron
  #8   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 65
Default find first positive number in column

Thank you Ron, I will give that a try

"Ron Rosenfeld" wrote:

On Mon, 11 Aug 2008 05:50:00 -0700, Sheila D
wrote:

Hi agfin and thanks for previous help
As a follow on from that once I have found the first positive value I need
to output that and then all following values in sequence ie from
1. -10
2. -1
3. 10
4. 5
5. 80
6.
7.

10 then 5 then 80
Is there a way to specify the next record(s) where value is present.

Sheila


Assuming your data is in A1:A7

Enter this formula in some cell, then fill down seven rows:

=IF(INDEX($A$1:$A$7,ROWS($1:1)-1+MATCH(TRUE,$A$1:$A$70,0))0,
INDEX($A$1:$A$7,ROWS($1:1)-1+MATCH(TRUE,$A$1:$A$70,0)),"")

As before, this is an **array** formula to be entered with
<ctrl<shift<enter.
--ron

Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
How to find what number in Column A is not included in Column B? Zhi Sheng Excel Discussion (Misc queries) 2 September 1st 08 02:42 AM
Find first positive value in a column George Excel Discussion (Misc queries) 5 October 27th 07 06:20 PM
Find max Row() number for a value in column Vlado Sveda Excel Worksheet Functions 12 January 20th 07 05:32 PM
FIND POSITIVE VALUE FIRSTROUNDKO via OfficeKB.com Excel Discussion (Misc queries) 2 March 23rd 06 01:43 AM
How do I find the first value in a column less than a number? redeucer Excel Worksheet Functions 6 November 4th 04 09:59 PM


All times are GMT +1. The time now is 05:31 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"