I am trying to have the spreadsheet return the payback period automatically.
That is, I want it to list on a cover page the period in which cumulative cash
flow first becomes positive. There must be some easy way to do this, but I
cannot find a built in function to handle it. Maybe I have to write a macro or
program to have it loop through the cumulative cash flow row, moving to the
next cell if the current one is negative and returning a reference to the top
cell (showing what period it is) when the loop finally hits a posive number?
Any guidance would be appreciated.
The following formula does this if the first positive number is less than
10,000. If it will be greater, increase the 10000 in the formula to a higher
number. This was tested on a sheet with the headers you want to return on row
1, The columns with the headers went from Column B to Column H (4 columns).
This formula returned the column header with the first positive value in in
row 10. This assumes that the numbers will be ascending since it returns the
header for the column with the minimum positive number in row 10.
=INDEX($B1:$E1,0,MATCH(MIN(IF($B$10:$E$10 <=
0,10000,$B$10:$E$10)),$B$10:$E$10,0))
Hope this does what you want.
Tom Ogilvy
In article <199805301916...@ladder01.news.aol.com>,
mamo...@aol.com says...