+ Reply to Thread
Results 1 to 22 of 22

IF cell Blank return the value to on or another cell

  1. #1
    Registered User
    Join Date
    03-20-2023
    Location
    Grasse
    MS-Off Ver
    2021
    Posts
    69

    IF cell Blank return the value to on or another cell

    Hello again guys,

    I need your help again because I'm trying to use an very simple If function and it doesn't work and don't understand why.

    I have the columns G and H which give me a result in the F column (G + H).

    I'm trying to tell excel to consider the value in the F column when there is one. If not I want to return the value to H or G column but it doesn't work.

    I tried with

    =IF(F8<>0;G8:H8;F8)

    with IF(BLANK(F8)

    and IF(F9=0; etc)


    Please find attached and excel fil with example.

    Thanks
    Attached Files Attached Files

  2. #2
    Forum Expert
    Join Date
    04-14-2009
    Location
    Taiwan
    MS-Off Ver
    Excel 2016,2019,O365
    Posts
    2,005

    Re: IF cell Blank return the value to on or another cell

    Maybe

    E8
    =IF(F8=0,G8+H8,F8)

    copied down.

  3. #3
    Registered User
    Join Date
    03-20-2023
    Location
    Grasse
    MS-Off Ver
    2021
    Posts
    69

    Re: IF cell Blank return the value to on or another cell

    no, not working

  4. #4
    Forum Expert etaf's Avatar
    Join Date
    10-22-2004
    Location
    Wittering, West Sussex, UK
    MS-Off Ver
    365 (Mac OSX) (16.83 (24031120))
    Posts
    8,749

    Re: IF cell Blank return the value to on or another cell

    can you give some examples
    F8 or any value in that column

    isblank(f8) will give a false and true

    BUT what does
    G8:H8
    mean ???
    its just a range
    Wayne
    if my assistance has helped, and only if you wish to , there is an "* Add Reputation" on the left hand side - you can add to my reputation here

    If you have a solution to your thread - Please mark your thread solved do the following: >
    Select Thread Tools-> Mark thread as Solved. To undo, select Thread Tools-> Mark thread as Unsolved.

  5. #5
    Registered User
    Join Date
    03-20-2023
    Location
    Grasse
    MS-Off Ver
    2021
    Posts
    69

    Re: IF cell Blank return the value to on or another cell

    G8:H8 means that I want him to consider one of the two values, either G8 or H8, just don't know how to write it.

    IF there is a value in F8 it comes from the sustraction/addition between G8 and H8. So if there is no value I want to return to one of the values of G8 and H8.

    For instance if I have G8 = 5 and H8 = 3 I'll have 8 or 2 in F8 and want consider only this value. If ever there is only G8= 5 and H8=blank OR H8=3 and G8= blank I want to make appear the value of G8 or H8 in the F8.

    Hope is clearer

  6. #6
    Forum Expert etaf's Avatar
    Join Date
    10-22-2004
    Location
    Wittering, West Sussex, UK
    MS-Off Ver
    365 (Mac OSX) (16.83 (24031120))
    Posts
    8,749

    Re: IF cell Blank return the value to on or another cell

    looking at this logically then

    return to where ???

    F8 has
    H8+G8

    and the value will depend on if those values in H8 and G8 are positive or negative

    if there is NO value in F8 , thats because G8 and H8 are blank, more likely 0 zero
    BUT
    as G8 or H8 is a formula , then will it ever return a blank and not just return zero ???

    Even if they are blank, then F8 will be zero

    but i dont see how they would be blank - with the sumproduct()

    as i say
    please would you provide some real examples in the sample spreadsheet, where cells are blank and expected results
    Last edited by etaf; 04-03-2023 at 01:37 PM.

  7. #7
    Registered User
    Join Date
    03-20-2023
    Location
    Grasse
    MS-Off Ver
    2021
    Posts
    69

    Re: IF cell Blank return the value to on or another cell

    here is a real example avec real values

    If there is a value in the column G I need to say excel to consider only this value every time when there is one, otherwise I want him to return to the J or K columns.

    There are 3 examples in the attached file.

    G9= - 43.4 so I want him to make appear only this value in D9

    G11 and G12 are blanks, so it should be either a negative value

    D11=-3.62 (cause J11=-3.62)

    neither positive

    D12=16.5 (cause K12=16.5)

    Thanks for your time !
    Attached Files Attached Files
    Last edited by stefan.g; 04-04-2023 at 03:34 AM.

  8. #8
    Forum Expert etaf's Avatar
    Join Date
    10-22-2004
    Location
    Wittering, West Sussex, UK
    MS-Off Ver
    365 (Mac OSX) (16.83 (24031120))
    Posts
    8,749

    Re: IF cell Blank return the value to on or another cell

    how about
    =IF(OR(J8="",K8=""),MAX(J8:K8),j8+k8)

    i have added to column C
    so it can be compared with column D

    But these are all different columns to your original question
    Attached Files Attached Files
    Last edited by etaf; 04-04-2023 at 04:04 AM.

  9. #9
    Registered User
    Join Date
    03-20-2023
    Location
    Grasse
    MS-Off Ver
    2021
    Posts
    69

    Re: IF cell Blank return the value to on or another cell

    yeah, sry about that. I was trying to make it more simple for you.

    it seems to works but if I put any value in G15, for example 20 , It doesn't return 20 in C15 but still -1.72.
    I see you make him calculate the value directly but if ever there is a value in G column It has to consider it and not to return to the J or K columns

    it's the same actually, I'll just use less columns

    I'll try and let you know !
    Last edited by stefan.g; 04-04-2023 at 04:17 AM.

  10. #10
    Forum Expert etaf's Avatar
    Join Date
    10-22-2004
    Location
    Wittering, West Sussex, UK
    MS-Off Ver
    365 (Mac OSX) (16.83 (24031120))
    Posts
    8,749

    Re: IF cell Blank return the value to on or another cell

    ok,
    so i'm really missing the details here

    probably me

    What 2 columns are we now looking at to see if blank ?

    you mention J , K and G now

    sorry , as i say probably me

    G9= - 43.4 so I want him to make appear only this value in D9
    WHY ???
    Is that because F is blank

    so are we testing columns F and G only

    =IF(OR(F8="",G8=""),MAX(F8:F8),F8+G8)

    G11 and G12 are blanks, so it should be either a negative value
    thats 2 different rows - row11 and row12 now compared

    and now
    D11=-3.62 (cause J11=-3.62)
    sorry , as i say maybe me - i'm just not following

    I your example = i was just following the values you had in the cells and matched those

  11. #11
    Registered User
    Join Date
    03-20-2023
    Location
    Grasse
    MS-Off Ver
    2021
    Posts
    69

    Re: IF cell Blank return the value to on or another cell

    my mistake !

    it works, thank you very much !

    I'll close the case and add the star of course

  12. #12
    Forum Expert etaf's Avatar
    Join Date
    10-22-2004
    Location
    Wittering, West Sussex, UK
    MS-Off Ver
    365 (Mac OSX) (16.83 (24031120))
    Posts
    8,749

    Re: IF cell Blank return the value to on or another cell

    oh, OK
    thats great

    but if not, just come back

  13. #13
    Registered User
    Join Date
    03-20-2023
    Location
    Grasse
    MS-Off Ver
    2021
    Posts
    69

    Re: IF cell Blank return the value to on or another cell

    Hi Etaf,

    I recently saw that there is an error in my formula.
    If I remember well you helped me with the formula in D column and Glenn Kennedy for the one in G:L columns. I'm not sure what would be easier to correct to meet the result I need to have in my file.

    I try to upload an example with an explanation of the expected result but there is an error
    Is there another way to send it ?
    Last edited by AliGW; 03-29-2024 at 03:41 AM. Reason: Please don't quote unnecessarily - use the Quick Reply button instead.

  14. #14
    Forum Expert etaf's Avatar
    Join Date
    10-22-2004
    Location
    Wittering, West Sussex, UK
    MS-Off Ver
    365 (Mac OSX) (16.83 (24031120))
    Posts
    8,749

    Re: IF cell Blank return the value to on or another cell

    I upload an example with an explanation of the expected result.
    ok,
    dont see the example

    also often useful to post the text in the post itself, so the spreadsheet does not need to be opened to see what the problem statement is - as other members may help if they saw the problem in a post

  15. #15
    Registered User
    Join Date
    03-20-2023
    Location
    Grasse
    MS-Off Ver
    2021
    Posts
    69

    Re: IF cell Blank return the value to on or another cell

    I need to do the sumproduct of multiple cells and then the subtraction of two values which could be positive and/or negatives.

    So I have

    =SUMPRODUCT(--(1+MOD((COLUMN(U20:BCH20)-COLUMN(U20));9)=1)*(U20:BCH20>0)*N(+U20:BCH20))=0

    for the positive and negative values and

    IF(IF(OR(G20="";H20="");MAX(G20:H20);G20+H20)=0;"";IF(OR(G20="";H20="");MAX(G20:H20);G20+H20))

    formula which is supposed to calculate the difference. But in the cells with the first formula there is an error in my result if ever I have positive and negative value at the same time.

    I try to upload the file but there is an error. I have "Upload of file failed" every time when I try

    Do I have to create a new post ?
    Last edited by stefan.g; 03-28-2024 at 07:18 PM.

  16. #16
    Forum Expert
    Join Date
    10-19-2021
    Location
    Brazil
    MS-Off Ver
    Office 365 V2401 w/ Win10 Home 64 Bit
    Posts
    2,014

    Re: IF cell Blank return the value to on or another cell

    Have you check the size of the file?

  17. #17
    Registered User
    Join Date
    03-20-2023
    Location
    Grasse
    MS-Off Ver
    2021
    Posts
    69

    Re: IF cell Blank return the value to on or another cell

    you were right, was too big
    Attached Files Attached Files
    Last edited by AliGW; 03-29-2024 at 03:41 AM. Reason: Please don't quote unnecessarily - use the Quick Reply button instead.

  18. #18
    Forum Expert
    Join Date
    10-19-2021
    Location
    Brazil
    MS-Off Ver
    Office 365 V2401 w/ Win10 Home 64 Bit
    Posts
    2,014

    Re: IF cell Blank return the value to on or another cell

    It is my understanding that you are double counting because you don't want to show the zeros, but it can be solved through formatting, so those formulas will be ok.

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


    It does not solve your question, but simplify the task for us.
    Attached Files Attached Files

  19. #19
    Registered User
    Join Date
    03-20-2023
    Location
    Grasse
    MS-Off Ver
    2021
    Posts
    69

    Re: IF cell Blank return the value to on or another cell

    I'm sorry about that. I didn't think to remove the if function and to left only the formula I'm interested in.
    Last edited by AliGW; 03-29-2024 at 03:40 AM. Reason: Please don't quote unnecessarily - use the Quick Reply button instead.

  20. #20
    Forum Moderator AliGW's Avatar
    Join Date
    08-10-2013
    Location
    Retired in Ipswich, Suffolk, but grew up in Sawley, Derbyshire (England)
    MS-Off Ver
    MS 365 Subscription Insider Beta Channel v. 2404 (Windows 11 22H2 64-bit)
    Posts
    80,869

    Re: IF cell Blank return the value to on or another cell

    If you are still needing assistance, please explain what you still need assistance with.
    Ali


    Enthusiastic self-taught user of MS Excel who's always learning!
    Don't forget to say "thank you" in your thread to anyone who has offered you help.
    You can reward them by clicking on * Add Reputation below their user name on the left, if you wish.

    Forum Rules (updated August 2023): please read them here.

  21. #21
    Registered User
    Join Date
    03-20-2023
    Location
    Grasse
    MS-Off Ver
    2021
    Posts
    69

    Re: IF cell Blank return the value to on or another cell

    Quote Originally Posted by AliGW View Post
    If you are still needing assistance, please explain what you still need assistance with.
    Yes, I still need help and I explained what I try to do and attached my file with an example of the result and the expected result. There is no confidential information, I left a few columns and rows cause was thinking it's an example of the real file and what kind of formula need to use.

    Don't understand very well where is the problem.
    Last edited by stefan.g; 03-29-2024 at 04:42 AM.

  22. #22
    Forum Moderator AliGW's Avatar
    Join Date
    08-10-2013
    Location
    Retired in Ipswich, Suffolk, but grew up in Sawley, Derbyshire (England)
    MS-Off Ver
    MS 365 Subscription Insider Beta Channel v. 2404 (Windows 11 22H2 64-bit)
    Posts
    80,869

    Re: IF cell Blank return the value to on or another cell

    It is far from clear (to me) what you still need help with.

+ 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. Replies: 2
    Last Post: 11-16-2021, 05:57 PM
  2. [SOLVED] How to return a sum only if a specific cell contains data, else return blank cell
    By Teeay5324 in forum Excel Formulas & Functions
    Replies: 11
    Last Post: 06-03-2017, 11:18 AM
  3. Return first non blank cell (cells have formulas that return blank)
    By BG1983 in forum Excel Formulas & Functions
    Replies: 2
    Last Post: 04-05-2016, 04:06 PM
  4. Replies: 4
    Last Post: 05-15-2014, 09:32 AM
  5. How to have a cell return blank when the target cell it is copying is blank
    By DanielWinning in forum Excel Formulas & Functions
    Replies: 6
    Last Post: 08-23-2013, 11:14 AM
  6. [SOLVED] Cell referenced in formula has no information displayed (shows blank), return blank cell
    By nunayobinezz in forum Excel Formulas & Functions
    Replies: 1
    Last Post: 08-07-2013, 04:51 PM
  7. Replies: 5
    Last Post: 03-23-2011, 07:09 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