+ Reply to Thread
Results 1 to 5 of 5

Flag previous row depending on value

  1. #1
    Registered User
    Join Date
    07-01-2021
    Location
    UK
    MS-Off Ver
    365
    Posts
    2

    Flag previous row depending on value

    HI,

    I have a simple dataset with a column containing flags. What Im looking to do is where this flag exists, mark the previous row eg:

    Screenshot 2021-07-01 at 10.07.07.png

    So where there is a '1' in column B, place a 'Y' in column 'C' for the previous rown.

    Many thanks,

    Fiorano

  2. #2
    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: Flag previous row depending on value

    =IF(B3=1,"Y","")

    in C2, copied down, should do that for you...
    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

  3. #3
    Forum Guru Pete_UK's Avatar
    Join Date
    12-31-2011
    Location
    Warrington, England
    MS-Off Ver
    Office 2019 (still learning)
    Posts
    25,412

    Re: Flag previous row depending on value

    Try this in C2:

    =IF(B3=1,"Y","")

    then copy down as required.

    Hope this helps.

    Pete

  4. #4
    Registered User
    Join Date
    07-01-2021
    Location
    UK
    MS-Off Ver
    365
    Posts
    2

    Re: Flag previous row depending on value

    Perfect thanks !

  5. #5
    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: Flag previous row depending on value

    You're welcome.



    It would be very nice if you were to just click the Add Reputation button at the foot of any of the posts of members who helped you reach a solution.

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

+ 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. Combobox add item depending on previous cell
    By antros48 in forum Excel Programming / VBA / Macros
    Replies: 5
    Last Post: 08-23-2019, 01:43 AM
  2. Changing cells depending on previous column
    By Vlad717 in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 01-11-2017, 08:56 PM
  3. [SOLVED] add % depending on previous selection
    By letrero in forum Excel Formulas & Functions
    Replies: 4
    Last Post: 03-03-2015, 10:42 AM
  4. [SOLVED] Sort depending of previous selection
    By luis6777 in forum Excel Formulas & Functions
    Replies: 8
    Last Post: 06-12-2014, 04:53 PM
  5. complex formula/ flag depending on a frequency
    By AGA in forum Excel General
    Replies: 3
    Last Post: 03-12-2012, 02:32 PM
  6. unhide or hide rows depending on previous row value
    By tinkerbelle in forum Excel Programming / VBA / Macros
    Replies: 9
    Last Post: 04-19-2010, 08:54 AM
  7. Print a page depending on flag
    By ezzy85 in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 05-19-2009, 09:51 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