+ Reply to Thread
Results 1 to 4 of 4

Subtracting two values in same column if criteria is met

  1. #1
    Registered User
    Join Date
    10-11-2014
    Location
    Faisalabad,Pakistan
    MS-Off Ver
    2010
    Posts
    2

    Subtracting two values in same column if criteria is met

    A B C
    1 Component RHrs Rhrs Since Last
    2 S021 200 0
    3 S021 400 200
    4 P011 600 0
    5 P011 900 300
    6 S021 1000 600
    7 S021 1200 ?
    8 P011 1400 ?

    Hi there.
    Need help with formula that calculates C7=B7-B6 if A7 and A6 are the latest values of same component S021.
    Also C8=B8-B5 as A8 and A5 are the latest entries of the same component P011.

    I wish to have this formula in C column so i could drag it down for any number of entries in A and B column.
    Attached Images Attached Images

  2. #2
    Valued Forum Contributor
    Join Date
    04-09-2013
    Location
    Bangalore, India
    MS-Off Ver
    Excel 2010
    Posts
    391

    Re: Subtracting two values in same column if criteria is met

    Hi,

    Try below array formula in C2 and copy down:

    Please Login or Register  to view this content.
    Confirm with Ctrl+Shift+Enter.

    Regards,

  3. #3
    Registered User
    Join Date
    10-11-2014
    Location
    Faisalabad,Pakistan
    MS-Off Ver
    2010
    Posts
    2

    Re: Subtracting two values in same column if criteria is met

    Thanks a lot. Its working perfectly.

  4. #4
    Valued Forum Contributor
    Join Date
    04-09-2013
    Location
    Bangalore, India
    MS-Off Ver
    Excel 2010
    Posts
    391

    Re: Subtracting two values in same column if criteria is met

    Thanks for the feedback and welcome back.

+ 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: 1
    Last Post: 07-03-2013, 12:14 AM
  2. Subtracting values from last column in selection
    By Azul in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 06-12-2012, 03:16 PM
  3. Subtracting column values based on another column having a date in it
    By laptopgraveyard in forum Excel - New Users/Basics
    Replies: 5
    Last Post: 02-10-2012, 05:44 AM
  4. Replies: 2
    Last Post: 10-05-2011, 12:43 PM
  5. subtracting column with criteria from other columns
    By TheGame0135 in forum Excel General
    Replies: 14
    Last Post: 07-08-2010, 11:04 AM

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