+ Reply to Thread
Results 1 to 11 of 11

Subtraction Formula with 2 conditions

  1. #1
    Registered User
    Join Date
    01-05-2024
    Location
    Canada
    MS-Off Ver
    2016
    Posts
    4

    Subtraction Formula with 2 conditions

    I need to subtract one cell from another cell, based on if there is text in another cell and if the number 1 is found in another cell.

    Anyone have a formula to help out?

    Thanks!
    Attached Files Attached Files
    Last edited by teetee1234; 01-05-2024 at 05:15 PM. Reason: Added Attachment

  2. #2
    Forum Moderator alansidman's Avatar
    Join Date
    02-02-2010
    Location
    Steamboat Springs, CO
    MS-Off Ver
    MS Office 365 Version 2406 Win 11 Home 64 Bit
    Posts
    23,982

    Re: Subtraction Formula with 2 conditions

    Fast answers need visual help. Please read the yellow banner at the top of this page on how to attach a file and a mocked up solution.
    Alan עַם יִשְׂרָאֵל חַי


    Change an Ugly Report with Power Query
    Database Normalization
    Complete Guide to Power Query
    Man's Mind Stretched to New Dimensions Never Returns to Its Original Form

  3. #3
    Forum Guru TMS's Avatar
    Join Date
    07-15-2010
    Location
    The Great City of Manchester, NW England ;-)
    MS-Off Ver
    MSO 2007,2010,365
    Posts
    44,753

    Re: Subtraction Formula with 2 conditions

    As a guess:
    Formula: copy to clipboard
    Please Login or Register  to view this content.
    Trevor Shuttleworth - Retired Excel/VBA Consultant

    I dream of a better world where chickens can cross the road without having their motives questioned

    'Being unapologetic means never having to say you're sorry' John Cooper Clarke


  4. #4
    Registered User
    Join Date
    01-05-2024
    Location
    Canada
    MS-Off Ver
    2016
    Posts
    4

    Re: Subtraction Formula with 2 conditions

    Thank you for your suggestion, that formula returned a value of Conditions not met. Those exact words appeared in my cell. I was hoping for the value of C2-D2.
    I will post an example shortly.
    Thanks again!

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

    Re: Subtraction Formula with 2 conditions

    Your sample has data in row 3. The solution in post #2 used row 2 so just replace A2 w/A3,... in the formula
    Ben Van Johnson

  6. #6
    Registered User
    Join Date
    01-05-2024
    Location
    Canada
    MS-Off Ver
    2016
    Posts
    4

    Re: Subtraction Formula with 2 conditions

    Hey Ben,
    I provided the sample after the post with the formula suggestion, so unfortunately my issue was not just the row, but thanks.
    That being said, when I tried the formula in my sample sheet it worked but when I apply to my large database it doesn't. However, I think I am close, so I will keep trying!!
    Thanks.

  7. #7
    Forum Moderator alansidman's Avatar
    Join Date
    02-02-2010
    Location
    Steamboat Springs, CO
    MS-Off Ver
    MS Office 365 Version 2406 Win 11 Home 64 Bit
    Posts
    23,982

    Re: Subtraction Formula with 2 conditions

    It is important when you are posting a question here that your sample data while anonymized be representative of your actual data so that you don't end up with a solution that does not work on your actual data. Maybe you should submit a new sample that is representative.

  8. #8
    Forum Guru TMS's Avatar
    Join Date
    07-15-2010
    Location
    The Great City of Manchester, NW England ;-)
    MS-Off Ver
    MSO 2007,2010,365
    Posts
    44,753

    Re: Subtraction Formula with 2 conditions

    As I explained, it was a guess based on your post.

    The revised formula based on your sample:
    Formula: copy to clipboard
    Please Login or Register  to view this content.

  9. #9
    Registered User
    Join Date
    01-05-2024
    Location
    Canada
    MS-Off Ver
    2016
    Posts
    4

    Re: Subtraction Formula with 2 conditions

    So strange that the formula solution provided above works in the sample I created but will not work in my actual database. I have attached the exact row from my database for your eyes and assistance.
    Attached Files Attached Files

  10. #10
    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
    28,408

    Re: Subtraction Formula with 2 conditions

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

  11. #11
    Forum Guru TMS's Avatar
    Join Date
    07-15-2010
    Location
    The Great City of Manchester, NW England ;-)
    MS-Off Ver
    MSO 2007,2010,365
    Posts
    44,753

    Re: Subtraction Formula with 2 conditions

    As JT says, re-enter AB6. Either press F2 and Enter. Or re type 1 and press Enter.

+ 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. [SOLVED] Subtraction Formula
    By depawl52 in forum Excel Formulas & Functions
    Replies: 13
    Last Post: 11-25-2021, 06:44 PM
  2. Subtraction Formula
    By ashleymarie08 in forum For Other Platforms(Mac, Google Docs, Mobile OS etc)
    Replies: 2
    Last Post: 10-27-2021, 06:06 PM
  3. Subtraction Formula
    By ashleymarie08 in forum Excel Formulas & Functions
    Replies: 1
    Last Post: 10-21-2021, 11:29 PM
  4. Range Subtraction / Matrix Subtraction - Large data set
    By excelrabbit in forum Excel Programming / VBA / Macros
    Replies: 5
    Last Post: 11-20-2015, 07:07 AM
  5. SUMIF subtraction with multiple conditions (OR)
    By Flash_82 in forum Excel General
    Replies: 2
    Last Post: 04-29-2014, 10:54 AM
  6. Replies: 8
    Last Post: 07-17-2013, 02:13 PM
  7. need help with a subtraction formula
    By adelissa in forum Excel - New Users/Basics
    Replies: 2
    Last Post: 01-10-2011, 12:57 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