+ Reply to Thread
Results 1 to 4 of 4

Make sum of all cells equal certain value

Hybrid View

  1. #1
    Registered User
    Join Date
    06-02-2014
    Posts
    6

    Make sum of all cells equal certain value

    Hi,
    First off, I'm sorry for the vague title, and/or if there is another thread on here explaining the answer. for some reason, I cannot think of how to phrase what I am looking to do.

    Let's say there are 3 cells A1:A3 and each cell is B1 divided by 3.

    Unfortunately, B1 is 10, so the cell value for A1:A3 is 3.3333.

    what I am looking to do are 2 things
    1) have the sum of all cells equal B1 (10 in this case)
    2)make each number an integer.

    so, an example might look like
    a1 = 4
    a2 = 3
    A3 = 3

    Is there a way to do this with a formula?

    Basically, I am just trying to create a shipping schedule for a lot of different parts, given a yearly quantity. so all shipments have to be whole numbers and the sum of all shipments must equal the yearly quantity.

    any ideas?

  2. #2
    Forum Expert
    Join Date
    11-28-2012
    Location
    Guatemala
    MS-Off Ver
    Excel 2010
    Posts
    2,394

    Re: Make sum of all cells equal certain value

    Yes!!! have one of the cells be the difference between the sum of all three divided by B1 and the truncated value of the other two

    c1 : sum(a1:a3)/b1-sum(c2:c3)
    c2 : round.down(a2/b1,0)
    c3 : round.down(a3/b1,0)

  3. #3
    Registered User
    Join Date
    06-02-2014
    Posts
    6

    Re: Make sum of all cells equal certain value

    that's a good idea and I think it will work.

    thanks!

  4. #4
    Forum Expert newdoverman's Avatar
    Join Date
    02-07-2013
    Location
    Port Dover, Ontario, Canada
    MS-Off Ver
    2010
    Posts
    10,330

    Re: Make sum of all cells equal certain value

    Something like this might work:

    A
    B
    1
    =INT(B1/3)
    11
    2
    =INT((B1-A1)/2)
    3
    =B1-SUM(A1:A2)


    Result:

    A
    B
    1
    3
    11
    2
    4
    3
    4
    <---------If you like someone's answer, click the star to the left of one of their posts to give them a reputation point for that answer.
    Ron W

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. How do I make blank cells not be equal?
    By afe5026 in forum Excel General
    Replies: 3
    Last Post: 10-03-2014, 03:37 PM
  2. make 2 cells equal and editable
    By mthemanj in forum Excel Formulas & Functions
    Replies: 1
    Last Post: 06-21-2012, 01:24 PM
  3. How do I make a cell equal to another cells value?
    By quikrich3 in forum Excel General
    Replies: 5
    Last Post: 06-23-2011, 06:07 PM
  4. Make cells equal 1
    By PJenkins in forum Excel General
    Replies: 5
    Last Post: 05-30-2007, 12:05 AM
  5. [SOLVED] How do I make a cell equal to another cells value and not it's fo.
    By TroutKing in forum Excel Formulas & Functions
    Replies: 2
    Last Post: 01-17-2005, 03:06 PM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1