+ Reply to Thread
Results 1 to 9 of 9

Find and show the last value from a row

  1. #1
    Forum Contributor
    Join Date
    12-18-2012
    Location
    Sweden
    MS-Off Ver
    Office 2016
    Posts
    158

    Find and show the last value from a row

    Hi.

    I am hoping this is easy but knowing my history with Excel, It's probably not :D

    I have attached the examplefile and what I want is a formula in the Z Column that gives me the last cell in the same row's value.

    So for example In Z2 I want the text from D2 to be shown since thats the last cell in that row with information (except the formula from the Z Column of course) and then the same for Z3-Z11.
    The file I am building will have about 150 row's to do the same with but a formula in Z2 finding the latest cell with text in it from row 2 and paste it there in Z2.

    I hope this makes sense.
    I am ok with adding another sheet and run the formula in there, as long as it still works as an o365 file uploaded to a sharepoint.

    examplefile.xlsx

    Thank you in advance!

  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 2403
    Posts
    44,135

    Re: Find and show the last value from a row

    If you ARE using O365, please update your profile to show your Product & version.

    =IFERROR(LOOKUP(2,1/(D2:Y2<>""),D2:Y2),"")

    copied down.
    Attached Files Attached Files
    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 Moderator Glenn Kennedy's Avatar
    Join Date
    07-08-2012
    Location
    Digital Nomad... occasionally based in Ireland.
    MS-Off Ver
    O365 (PC) V 2403
    Posts
    44,135

    Re: Find and show the last value from a row

    or... an O365 spill array version:

    =BYROW(D2:Y20,LAMBDA(x,IFERROR(LOOKUP(2,1/(x<>""),x),"")))
    Attached Files Attached Files

  4. #4
    Forum Expert Pepe Le Mokko's Avatar
    Join Date
    05-14-2009
    Location
    Belgium
    MS-Off Ver
    O365 v 2402
    Posts
    13,453

    Re: Find and show the last value from a row

    Try
    Formula: copy to clipboard
    Please Login or Register  to view this content.
    and pull down
    ( change the ; to , if needed)

  5. #5
    Forum Contributor
    Join Date
    12-18-2012
    Location
    Sweden
    MS-Off Ver
    Office 2016
    Posts
    158

    Re: Find and show the last value from a row

    Quote Originally Posted by Pepe Le Mokko View Post
    Try
    Formula: copy to clipboard
    Please Login or Register  to view this content.
    and pull down
    ( change the ; to , if needed)
    This worked great! Thank you! (I would assume others worked as well but since this worked I wont be testing all of them but I want to thank everyone for their contribution so far!)

    As an addition. Which may make this way harder but this is something I just realized when I added this code to my file and saw it work.

    In row 1 There will be timestamps (Worded: Timestamp: 2022-12-13 for example, manually written). above each info line. I have added a new examplefile with this first fix applied & working.
    Examplefile 2.xlsx

    So what I would want in AA is the Testheader that is the header for that cell which is returned in Z:Z.

    Basically I want AA to show what the date is for the last comment made so the easiest way would be if AA2 for example check Z2, see's that the value is Info 4 and then shows the value for Info 4's header. If that makes sense?

    I dont know if I should make a new thread or continue here? And mods/Smarter people please let me know.

  6. #6
    Forum Expert Pepe Le Mokko's Avatar
    Join Date
    05-14-2009
    Location
    Belgium
    MS-Off Ver
    O365 v 2402
    Posts
    13,453

    Re: Find and show the last value from a row

    Supposing no duplicate strings in the same row try =INDEX($D$1:$Y$1;MATCH($Z2;$D2:$Y2;0))
    If not,replace $Z2 with the formula added earlier
    (I'm not a big fan of the IFERROR function )
    Attached Files Attached Files

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

    Re: Find and show the last value from a row

    If duplicate strings are possible, please try in AA2 nearly de same formula as in Z2 and copy down:
    Formula: copy to clipboard
    Please Login or Register  to view this content.

  8. #8
    Forum Contributor
    Join Date
    12-18-2012
    Location
    Sweden
    MS-Off Ver
    Office 2016
    Posts
    158

    Re: Find and show the last value from a row

    Quote Originally Posted by HansDouwe View Post
    If duplicate strings are possible, please try in AA2 nearly de same formula as in Z2 and copy down:
    Formula: copy to clipboard
    Please Login or Register  to view this content.
    This worked great Thank you very much!

    Pepe I didnt get yours to work but that's probably due to my own lack of knowledge since the example file worked but I couldnt transfer it to my main file for some reason, but thank you for the effort & help!

    This seems to have been all I needed for today so Ill mark it solved and add rep on you all, thank you all for the great and quick support!

    And I will also check to make sure my version is correct everywhere (i usually work with the app, but this specific file needs to be usable on sharepoint but ill doublecheck!)

    Again, thank you all and I wish you all a great and fantastic holiday season!

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

    Re: Find and show the last value from a row

    You are welcome, thanks for the feedback and rep . Glad to have helped.

+ 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] Find max/min and show sheet name
    By miso.dca in forum Excel Formulas & Functions
    Replies: 3
    Last Post: 11-14-2017, 11:29 AM
  2. [SOLVED] Find the x number and show the value in a cell
    By Lensmeister in forum Excel General
    Replies: 2
    Last Post: 07-14-2015, 07:57 AM
  3. [SOLVED] How I can find and then show it in new sheet
    By pedjvak in forum Excel Programming / VBA / Macros
    Replies: 11
    Last Post: 10-09-2014, 09:06 AM
  4. Search, Find & Show
    By artofsound in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 11-01-2013, 10:14 AM
  5. Find value and show it in another sheet
    By tsosmoulis in forum Excel General
    Replies: 2
    Last Post: 02-11-2008, 09:58 AM
  6. Find a value and show it's location
    By MattOG in forum Excel Formulas & Functions
    Replies: 4
    Last Post: 06-14-2007, 02:07 PM
  7. [SOLVED] How to find all fields with X value and show corresponding Y value
    By Richard in forum Excel General
    Replies: 4
    Last Post: 08-11-2006, 08:10 AM

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