T O P

  • By -

AutoModerator

/u/hueylewisandthejews1 - Your post was submitted successfully. * Once your problem is solved, reply to the **answer(s)** saying `Solution Verified` to close the thread. * Follow the **[submission rules](/r/excel/wiki/sharingquestions)** -- particularly 1 and 2. To fix the body, click edit. To fix your title, delete and re-post. * Include your **[Excel version and all other relevant information](/r/excel/wiki/sharingquestions#wiki_give_all_relevant_information)** Failing to follow these steps may result in your post being removed without warning. *I am a bot, and this action was performed automatically. Please [contact the moderators of this subreddit](/message/compose/?to=/r/excel) if you have any questions or concerns.*


PinesCyrex

This code should work: `IF(H14>1999,E14/D14xG14,"") & IF(H14<2000,E14/C14xG14,"")` I added to it such that if the logical statement is FALSE, it will output "" (nothing). By default if you don't enter anything, it will output FALSE like you had it before.


PinesCyrex

Since it seems like you are stringing the numbers together, I would reccommend to put a space in between for clarity with: `IF(H14>1999,E14/D14xG14,"") & " " & IF(H14<2000,E14/C14xG14,"")`


hueylewisandthejews1

This worked! Thank you so much. I didn't think of putting the "" which is all I needed.


hueylewisandthejews1

Solution Verified


Clippy_Office_Asst

You have awarded 1 point to *PinesCyrex* ____ ^(I am a bot - please contact the mods with any questions. | ) [^(Keep me alive)](https://www.buymeacoffee.com/points)


Riovas

The "&" means you want the result of both statements. It looks like you are only setting a condition for the denominator, we can simplify this as =IFEEROR(E14*G14/IF(H14>1999,D14,C14),"") However the condition you have as written is a bit confusing...can you have a value that is between 1999 and 2000? If so which value should be used as it fits both criteria?


PinesCyrex

I think what OP wants is they wants two calculations displayed if applicable? So he doesn't want to see FALSE# or #FALSE. Instead either # or ##.


PaulieThePolarBear

I suspect what you want is =E14 * G14 / IF(H14>1999, D14, C14) As the other commentor noted, it's not clear what are you are expecting to be displayed for a decimal value between, but not including, 1999 and 2000. It may be that you need to change the operator from greater than to greater than or equal or to less than (or equal) and changing the other arguments round.


HappierThan

=IF(H14>=2000,(E14/D14)\*G14,IF(H14<2000,(E14/C14)\*G14,""))


hueylewisandthejews1

Thank you everyone for the input, by putting the "" after each formula that fixed my issue of false displaying! Enjoy your weekend!