Avatar of Smilesxl
 asked on

Excel Macro - Return looks up a column to find lower number.

Spreadsheet has "Level"  in column A, "Part #" in column B, in column C is "Next Level Part #" and is what I need to populate.

Usually there is a level 1, that is the highest and it will have in the next rows, all of it's level 2 parts and some level 3's and 4's.   Essentially I need a column that shows the next level up the part number in that row.  So if it is a level 4 part, I need the level 3 part to be populated in the "Next Level Part #" row.   So essentially I need it to look at the level of the row it is in, then look above to the next lower number, and return the "Part #" of that row.    

Hope someone can help.  I used to do this stuff, but have not even looked at Excel in 5 years.  (I know luck me, right).   But I have forgotten most of what I used to know.  It is not like riding a bike.
Microsoft Excel

Avatar of undefined
Last Comment

8/22/2022 - Mon
Ejgil Hedegaard

Log in or sign up to see answer
Become an EE member today7-DAY FREE TRIAL
Members can start a 7-Day Free trial then enjoy unlimited access to the platform
Sign up - Free for 7 days
Learn why we charge membership fees
We get it - no one likes a content blocker. Take one extra minute and find out why we block content.
Not exactly the question you had in mind?
Sign up for an EE membership and get your own personalized solution. With an EE membership, you can ask unlimited troubleshooting, research, or opinion questions.
ask a question

I am not sure how to call a custom function?  I type in =NextLevelPartNumber (range?).  Never mind, I got it, thanks.

Thank you so much!  Great solution.
Experts Exchange has (a) saved my job multiple times, (b) saved me hours, days, and even weeks of work, and often (c) makes me look like a superhero! This place is MAGIC!
Walt Forbes