LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #5   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 25
Default decrease integers to zero

That's awesome, Harlan - thanks a bunch.

Here's the formula for Column B (column A has numbers in it).
=INT($B$20*A2).

"Harlan Grove" wrote:

Andi wrote...
....
At the top of Column B, I have a total amount. I have a formula based
calculation in Column B. Based on these numbers, I have a 'running total' at
the bottom of Column B. (B1-sum(B2:B17)). Some of the cells formuals come
to zero at the bottom cells of the column. I would like to add 1 to each
cell, starting with those that have a zero and then back to the top with the
higher numbers until the 'running total' is zero.

....

It may be possible to do this with a single array formula in B2:B17,
but you'd need to show the formulas currently in B2:B17.

It could be done in C2:C17 using the formulas

C2:
=B2+INT(B$19/ROWS(B$2:B$17))+(MOD(B$19,ROWS(B$2:B$17))
MOD(COUNTIF(B$2:B$17,"0")-ROWS(B2:B$17),ROWS(B$2:B$17)))


Fill C2 down into C3:C17.



 
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
two integers in one cell KRK New Users to Excel 3 June 29th 08 12:06 AM
Sum all integers of a given number pchr Excel Worksheet Functions 3 June 8th 07 04:18 PM
Rounding to Multiples of Integers? ConfusedNHouston Excel Discussion (Misc queries) 5 February 1st 07 11:38 PM
A list of Consecutive Integers, can I search for missing integers CM Excel Worksheet Functions 4 September 2nd 05 06:38 PM
converting to Integers bmordhorst Excel Worksheet Functions 5 January 6th 05 04:55 PM


All times are GMT +1. The time now is 10:19 AM.

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"