+ Reply to Thread
Results 1 to 11 of 11

Need help to find a formula to repeat a previous value until there there is new value

  1. #1
    Registered User
    Join Date
    09-07-2022
    Location
    Australia
    MS-Off Ver
    Office365
    Posts
    6

    Lightbulb Need help to find a formula to repeat a previous value until there there is new value

    Hello!
    I am finding very challenging on getting a correct formula on below.

    Can you please help me in creating a formula to repeat the science score for each student name until there is a new science score.
    I have attached the excel file and highly appreciate if someone can give me some insights on defining the correct formula.
    Help in formula.xlsxHelp in formula.JPG
    Last edited by Rasike.desilva; 09-07-2022 at 10:45 PM.

  2. #2
    Forum Guru HansDouwe's Avatar
    Join Date
    06-21-2022
    Location
    Nederland
    MS-Off Ver
    365 V2403 (Build 17330.20000)
    Posts
    6,419

    Re: Need help to find a formula to repeat a previous value until there there is new value

    Please try in F2 and copy down:
    Formula: copy to clipboard
    Please Login or Register  to view this content.

  3. #3
    Registered User
    Join Date
    09-07-2022
    Location
    Australia
    MS-Off Ver
    Office365
    Posts
    6

    Re: Need help to find a formula to repeat a previous value until there there is new value

    Quote Originally Posted by HansDouwe View Post
    Please try in F2 and copy down:
    Formula: copy to clipboard
    Please Login or Register  to view this content.
    Thanks for the suggestion. This does not work as you have different student names. So this formula will repeat the value as well as overrides other students latest scores.
    Thank you

  4. #4
    Forum Guru HansDouwe's Avatar
    Join Date
    06-21-2022
    Location
    Nederland
    MS-Off Ver
    365 V2403 (Build 17330.20000)
    Posts
    6,419

    Re: Need help to find a formula to repeat a previous value until there there is new value

    Did you try this formula in F2 and copy down?
    Everything seems to be working fine in your sample workbook.
    See attachment.
    Attached Files Attached Files

  5. #5
    Registered User
    Join Date
    09-07-2022
    Location
    Australia
    MS-Off Ver
    Office365
    Posts
    6

    Re: Need help to find a formula to repeat a previous value until there there is new value

    Quote Originally Posted by HansDouwe View Post
    Did you try this formula in F2 and copy down?
    Everything seems to be working fine in your sample workbook.
    See attachment.
    Help in formula-1.JPG

    Thanks for your support. I have highlighted in yellow colour where the formula is not working and what should be the correct value. This is why this formula is not working.
    Many thanks
    Rasike

  6. #6
    Forum Guru HansDouwe's Avatar
    Join Date
    06-21-2022
    Location
    Nederland
    MS-Off Ver
    365 V2403 (Build 17330.20000)
    Posts
    6,419

    Re: Need help to find a formula to repeat a previous value until there there is new value

    O in that way, we need to take more steps.

    Here is a new solution:

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

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

    Try in M2 and copy down:
    Formula: copy to clipboard
    Please Login or Register  to view this content.

    Try in O2:
    Formula: copy to clipboard
    Please Login or Register  to view this content.
    Attached Files Attached Files
    Last edited by HansDouwe; 09-07-2022 at 10:01 PM. Reason: typo corrections (but not in the formula)

  7. #7
    Forum Contributor
    Join Date
    03-05-2018
    Location
    Tbilisi, Georgia
    MS-Off Ver
    2013, 2016
    Posts
    271

    Re: Need help to find a formula to repeat a previous value until there there is new value

    Try this:
    PHP Code: 
    =LOOKUP(2,1/(($D$2:D2=D2)/($E$2:E2<>"")),$E$2:E2
    Attached Files Attached Files
    Last edited by T.I.; 09-07-2022 at 10:05 PM.

  8. #8
    Forum Expert
    Join Date
    02-10-2019
    Location
    Georgia, USA
    MS-Off Ver
    Office 365
    Posts
    2,831

    Re: Need help to find a formula to repeat a previous value until there there is new value

    Or, in cell G2 try:

    =LET(a,FILTER(E2:E$2,(E2:E$2<>"")*(D2:D$2=D2)),INDEX(a,COUNT(a)))

    Copy down.
    Attached Files Attached Files

  9. #9
    Registered User
    Join Date
    09-07-2022
    Location
    Australia
    MS-Off Ver
    Office365
    Posts
    6

    Re: Need help to find a formula to repeat a previous value until there there is new value

    Thank you very much for your time. This is actually working

  10. #10
    Registered User
    Join Date
    09-07-2022
    Location
    Australia
    MS-Off Ver
    Office365
    Posts
    6

    Re: Need help to find a formula to repeat a previous value until there there is new value

    Quote Originally Posted by T.I. View Post
    Try this:
    PHP Code: 
    =LOOKUP(2,1/(($D$2:D2=D2)/($E$2:E2<>"")),$E$2:E2
    Thank you very much for your time. This is actually working

  11. #11
    Registered User
    Join Date
    09-07-2022
    Location
    Australia
    MS-Off Ver
    Office365
    Posts
    6

    Re: Need help to find a formula to repeat a previous value until there there is new value

    Quote Originally Posted by Gregb11 View Post
    Or, in cell G2 try:

    =LET(a,FILTER(E2:E$2,(E2:E$2<>"")*(D2:D$2=D2)),INDEX(a,COUNT(a)))

    Copy down.
    Thank you very much for your time. This is actually working

+ 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. Formula To Find Previous Occurrence
    By gibbsa08 in forum Excel Formulas & Functions
    Replies: 7
    Last Post: 12-10-2019, 08:13 AM
  2. [SOLVED] Find certain word, copy and paste cell in previous row if previous row is blank
    By steven_e in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 06-19-2013, 12:53 PM
  3. [SOLVED] Make 3 rows relative to 1 row on previous sheet, then REPEAT!
    By BizzyBob in forum Excel Programming / VBA / Macros
    Replies: 5
    Last Post: 06-08-2013, 05:52 PM
  4. [SOLVED] Find last previous non blank value and summarise previous 6 months
    By Lady_Shaz in forum Excel General
    Replies: 7
    Last Post: 12-11-2012, 06:20 AM
  5. Replies: 12
    Last Post: 06-06-2012, 01:43 PM
  6. Macro Formula needed to find a value and remember the row of the value, repeat
    By 66Deuce in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 07-30-2011, 09:57 PM
  7. Replies: 1
    Last Post: 03-25-2005, 01:06 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