+ Reply to Thread
Results 1 to 6 of 6

Only calculate a cell when both cells contain a value

  1. #1
    Forum Contributor
    Join Date
    08-29-2013
    Location
    CT
    MS-Off Ver
    Excel 2016 Mac
    Posts
    268

    Only calculate a cell when both cells contain a value

    I have sheet where percent change is calculated. All of the data isn't put in at once, so i don't want it to a calculate the percent change until both cells contain a number.

    Here is the formula i am using: =IFERROR((D4-B4)/B4,"")

    Is there a way to do this?

    Right now when i fill in the first value it automatically returns a percent change of -100%, i want it to wait until both cells are filled with data.

    Thanks in avance

    Los

  2. #2
    Forum Guru
    Join Date
    03-02-2006
    Location
    Los Angeles, Ca
    MS-Off Ver
    WinXP/MSO2007;Win10/MSO2016
    Posts
    12,600

    Re: Only calculate a cell when both cells contain a value

    =if(count(b4,d4)=2,(d4-b4)/b4,"")
    Ben Van Johnson

  3. #3
    Forum Moderator - RIP Richard Buttrey's Avatar
    Join Date
    01-14-2008
    Location
    Stockton Heath, Cheshire, UK
    MS-Off Ver
    Office 365, Excel for Windows 2010 & Excel for Mac
    Posts
    29,464

    Re: Only calculate a cell when both cells contain a value

    Hi,

    One way

    Formula: copy to clipboard
    Please Login or Register  to view this content.
    Richard Buttrey

    RIP - d. 06/10/2022

    If any of the responses have helped then please consider rating them by clicking the small star icon below the post.

  4. #4
    Forum Contributor
    Join Date
    08-29-2013
    Location
    CT
    MS-Off Ver
    Excel 2016 Mac
    Posts
    268

    Re: Only calculate a cell when both cells contain a value

    that works but i also don't want to lose the if error part, if the donimator is zero i want it to also return a blank....

    is this possible?

    Los

  5. #5
    Forum Moderator - RIP Richard Buttrey's Avatar
    Join Date
    01-14-2008
    Location
    Stockton Heath, Cheshire, UK
    MS-Off Ver
    Office 365, Excel for Windows 2010 & Excel for Mac
    Posts
    29,464

    Re: Only calculate a cell when both cells contain a value

    Hi,

    OK, instead

    Formula: copy to clipboard
    Please Login or Register  to view this content.

  6. #6
    Forum Contributor
    Join Date
    08-29-2013
    Location
    CT
    MS-Off Ver
    Excel 2016 Mac
    Posts
    268

    Re: Only calculate a cell when both cells contain a value

    that works !!!!!

    thank you and repped

    Los

+ 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. Calculate two cells based on cell color
    By jaycee66 in forum Excel Formulas & Functions
    Replies: 1
    Last Post: 07-25-2013, 12:03 PM
  2. Calculate cells if other cell contains a value - Need help with the logic.
    By audioboxer in forum Excel Formulas & Functions
    Replies: 8
    Last Post: 07-15-2013, 04:21 PM
  3. [SOLVED] Trying calculate the value of one cell depending on value of two different cells
    By dheads in forum Excel Formulas & Functions
    Replies: 2
    Last Post: 05-10-2013, 03:06 PM
  4. [SOLVED] Calculate a value to a cell if 2 cells contain the same value
    By craig0988 in forum Excel Formulas & Functions
    Replies: 5
    Last Post: 08-24-2012, 12:34 PM
  5. Compare 2 cells to calculate a third cell
    By lboyd in forum Excel Programming / VBA / Macros
    Replies: 9
    Last Post: 08-31-2010, 06:11 AM

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