?
Solved

Excel Offset Formula Question

Posted on 2013-02-04
4
Medium Priority
?
301 Views
Last Modified: 2013-02-05
In the attached spreadsheet, I have two columns of data, with the top row returning the last cell of data with an offset formula, as it should. However, I'd like to get a formula that returns the last value in the column -- only if the one next to it is filled.

In my example, I'd like the date 01/31 returned, instead of the date 02/04.

How do I write this type of formula?

Thanks!
EE2.xlsx
0
Comment
Question by:Tim Jackoboice
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
4 Comments
 
LVL 24

Accepted Solution

by:
Steve earned 2000 total points
ID: 38853988
OK, I am not sure if I am grasping the question fully, but attached is the file ammended for the first column to return the coresponding cell to column B...

the formula is the same as in B1 except that is OFFSETS -1 from the result of B1

=OFFSET(B$2,MATCH(MAX(B$2:B363)+1,B$2:B363,1)-1,-1)
EE2.xlsx
0
 
LVL 50

Expert Comment

by:barry houdini
ID: 38854610
You could use LOOKUP to get the last time from column B in B1, i.e.

=LOOKUP(9.99E+307,B3:B366)

then in A1 to get the corresponding date try

=LOOKUP(9.99E+307,B3:B366,A3:A366)

regards, barry
0
 

Author Closing Comment

by:Tim Jackoboice
ID: 38854729
Thanks, guys. I like the OFFSET rather than the LOOKUP in this case, because only one formula needs to be entered. Works perfectly ... thanks!
0
 
LVL 50

Expert Comment

by:barry houdini
ID: 38854914
I'm not suggesting you use any more formulas than you are currently using - the first LOOKUP replaces your B1 formula and the second replaces the A1 formula.

LOOKUP and MATCH use the same technique here to find the last value, but with MATCH you only get the position....and OFFSET is being used to get the value from that position.......but with LOOKUP you don't need that two stage approach - it just gives you the last value directly......

regards, barry
0

Featured Post

Free Tool: Subnet Calculator

The subnet calculator helps you design networks by taking an IP address and network mask and returning information such as network, broadcast address, and host range.

One of a set of tools we're offering as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

This tutorial explains how to create a series of drop-down lists that are dependent upon prior selections to guide (“force”) the user to make the correct selection and reduce data errors within Microsoft Excel. Excel 2010 was used for this tutorial;…
Excel can be a tricky bit of software to get your head around. Whilst you’ll be able to eventually get to grips with the basic understanding of how to get by, there are a few Excel tips that not everybody will even know about let alone know how to d…
The viewer will learn how to create two correlated normally distributed random variables in Excel, use a normal distribution to simulate the return on different levels of investment in each of the two funds over a period of ten years, and, create a …
This Micro Tutorial will demonstrate on a Mac how to change the sort order for chart legend values and decrpyt the intimidating chart menu.

764 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question