+ Reply to Thread
Results 1 to 12 of 12

How to return a sum only if a specific cell contains data, else return blank cell

Hybrid View

  1. #1
    Registered User
    Join Date
    06-03-2017
    Location
    Total RV Gypsy
    MS-Off Ver
    2007
    Posts
    7

    How to return a sum only if a specific cell contains data, else return blank cell

    It has me stumped. if(c10=0,"",=sumC8:C10) I have tried various alternates including nested ifs, no =, sumif and additional parentheses to no avail. Sorry to join the group and jump right in with a request for help that probably makes me look pretty silly, but I do have some things to offer. Thanks in advance.

    by C10=0 I mean contains no data. It is formatted for currency.
    Last edited by Teeay5324; 06-03-2017 at 10:37 AM. Reason: Improper Title

  2. #2
    Forum Expert
    Join Date
    02-14-2009
    Location
    .
    MS-Off Ver
    ................
    Posts
    2,840

    Re: This should be so very simple

    Welcome to the forum...

    Your post does not comply with Rule 1 of our Forum RULES. Your post title should accurately and concisely describe your problem.

    Use terms appropriate to a Google search. Poor thread titles, like Please Help, Urgent, Need Help, Formula Problem, Code Problem, and Need Advice will be addressed according to the OP's experience in the forum: If you have less than 10 posts, expect (and respond to) a request to change your thread title. If you have 10 or more posts, expect your post to be locked, so you can start a new thread with an appropriate title.

    To change a Title go to your first post, click EDIT then Go Advanced and change your title, if 2 days have passed ask a moderator to do it for you.

    (This thread should receive no further responses until this moderation request is fulfilled, as per Forum Rule 7)

  3. #3
    Registered User
    Join Date
    06-03-2017
    Location
    Total RV Gypsy
    MS-Off Ver
    2007
    Posts
    7

    Re: This should be so very simple

    Thank you for the correction and sorry for unintentionally disobeying the forum rules. It will be corrected post-haste.

  4. #4
    Registered User
    Join Date
    06-03-2017
    Location
    Total RV Gypsy
    MS-Off Ver
    2007
    Posts
    7

    Re: This should be so very simple

    As soon as I saw your response, I saw my problem. I did indeed try that exact syntax, with one major flaw - no "=" to begin the formula. Problem solved, thank you.

  5. #5
    Forum Expert
    Join Date
    02-14-2009
    Location
    .
    MS-Off Ver
    ................
    Posts
    2,840

    Re: How to return a sum only if a specific cell contains data, else return blank cell

    Thank you for the update.

    Does

    =IF(C10=0,"",SUM(C8:C10))

    not work for you?

    I appreciate you mentioned 'no =' but perhaps something else was wrong with the syntax. If that formula does not work then upload a sample workbook.

  6. #6
    Registered User
    Join Date
    06-03-2017
    Location
    Total RV Gypsy
    MS-Off Ver
    2007
    Posts
    7

    Re: How to return a sum only if a specific cell contains data, else return blank cell

    Quote Originally Posted by cytop View Post
    Thank you for the update.

    Does

    =IF(C10=0,"",SUM(C8:C10))

    not work for you?

    I appreciate you mentioned 'no =' but perhaps something else was wrong with the syntax. If that formula does not work then upload a sample workbook.
    As soon as I saw your response, I saw my problem. I did indeed try that exact syntax, with one major flaw - no "=" to begin the formula. Problem solved, thank you.

  7. #7
    Forum Expert
    Join Date
    05-05-2015
    Location
    UK
    MS-Off Ver
    Microsoft Excel for Microsoft 365 MSO (Version 2402 Build 16.0.17328.20068) 64-bit
    Posts
    31,174

    Re: How to return a sum only if a specific cell contains data, else return blank cell

    If that takes care of your original question, please select Thread Tools from the menu link above and mark this thread as SOLVED. Thanks.

  8. #8
    Registered User
    Join Date
    06-03-2017
    Location
    Total RV Gypsy
    MS-Off Ver
    2007
    Posts
    7

    Re: How to return a sum only if a specific cell contains data, else return blank cell

    Quote Originally Posted by JohnTopley View Post
    If that takes care of your original question, please select Thread Tools from the menu link above and mark this thread as SOLVED. Thanks.
    That was going to be my next question. Well moderated forum here, thanks for everything.

  9. #9
    Forum Guru MarvinP's Avatar
    Join Date
    07-23-2010
    Location
    Woodinville, WA
    MS-Off Ver
    Office 365
    Posts
    16,445

    Re: How to return a sum only if a specific cell contains data, else return blank cell

    Hi Teeay and welcome to the forum,

    You need to edit your first post and go to advanced and edit the thread title to something like:

    What is the difference between C10= 0 and C10 = ""?

    That might be a much better thread title so we could find it in the future. (I also hope it answers your question.)

    Perhaps you want
    If(Len(C10)=0, , )
    One test is worth a thousand opinions.
    Click the * Add Reputation below to say thanks.

  10. #10
    Registered User
    Join Date
    06-03-2017
    Location
    Total RV Gypsy
    MS-Off Ver
    2007
    Posts
    7

    Re: How to return a sum only if a specific cell contains data, else return blank cell

    Quote Originally Posted by MarvinP View Post
    Hi Teeay and welcome to the forum,

    You need to edit your first post and go to advanced and edit the thread title to something like:

    What is the difference between C10= 0 and C10 = ""?

    That might be a much better thread title so we could find it in the future. (I also hope it answers your question.)

    Perhaps you want
    If(Len(C10)=0, , )
    Thank you for your advice.

  11. #11
    Forum Moderator Glenn Kennedy's Avatar
    Join Date
    07-08-2012
    Location
    Digital Nomad... occasionally based in Ireland.
    MS-Off Ver
    O365 (PC) V 2406
    Posts
    44,662

    Re: How to return a sum only if a specific cell contains data, else return blank cell

    if the solution offered above doesn't work....

    Will you please attach a SMALL sample Excel workbook (10-20 rows of data is usually enough)? Please don't attach a picture of one (no-one will want to re-type all your stuff before starting).

    1. Make sure that your sample data are truly REPRESENTATIVE of your real data. The use of unrepresentative data is very frustrating and can lead to long delays in reaching a solution.

    2. Make sure that your desired solution is also shown (mock up the results manually).

    3. Make sure that all confidential information is removed first!!

    4. Try to avoid using merged cells. They cause lots of problems!

    Unfortunately the attachment icon doesn't work at the moment. So, to attach an Excel file you have to do the following: Just before posting, scroll down to Go Advanced and then scroll down to Manage Attachments. Now follow the instructions at the top of that screen.
    Glenn




    None of us get paid for helping you... we do this for fun. So DON'T FORGET to say "Thank You" to all who have freely given some of their time to help YOU

  12. #12
    Registered User
    Join Date
    06-03-2017
    Location
    Total RV Gypsy
    MS-Off Ver
    2007
    Posts
    7

    Re: How to return a sum only if a specific cell contains data, else return blank cell

    Thank you for the information, I will keep it in mind for future posts.

+ 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. Simple (?) chart prob--Needing a simple solution!
    By baloo308 in forum Excel Charting & Pivots
    Replies: 1
    Last Post: 10-06-2016, 12:24 PM
  2. Replies: 4
    Last Post: 12-07-2012, 11:49 AM
  3. A simple question requiring a simple answer
    By Pedros in forum Excel General
    Replies: 3
    Last Post: 07-18-2006, 06:45 AM
  4. Simple Simple Excel usage question
    By BookerW in forum Excel General
    Replies: 1
    Last Post: 06-23-2005, 05:05 PM
  5. Make it more simple or intuitive to do simple things
    By Vernie in forum Excel Charting & Pivots
    Replies: 1
    Last Post: 03-16-2005, 12:06 AM
  6. Posting data from a simple form to a simple database
    By clacka in forum Excel General
    Replies: 0
    Last Post: 01-30-2005, 04:37 PM

Tags for this Thread

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