Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 30
Default lookup time value

I'm trying to lookup the time value 4:05:00 PM or the next highest time value.
I have:
B19 = 4:05:00 PM C19 = VLOOKUP(B19,D:D,1) D25 = 4:05:13 PM
D26 = 4:05:10 PM
D27 = 4:05:09 PM
D28 = 4:00:06 PM

I thought I'd get 4:00:06 PM as my answer but all I keep getting is 8:02:49
AM. What am I doing wrong?
  #2   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 506
Default lookup time value

You have mentioned that you would like to get the next highets time value for
4:05:00 PM, but at the same time you are saying that you would like to get
4:00:06 PM as your result. How it's possbile?

Becuase the value you want to get as a result should be greater than 4:05:00
PM, but the value you are mentioning as your desired result is 4:00:06 PM .
Just have a look in these times you will notice that 4:00:06 PM is lower
value when comparing to 4:05:00 PM. Becuase the 06 is seconds not minutes.

Apart from this the Vlookup formula is not perfect. = VLOOKUP(B19,D:D,1) it
should be like this =VLOOKUP(B19,D:D,1,FALSE) OR = VLOOKUP(B19,D:D,1,0). But
this also will not get the next highest time value.

You can use =LARGE(D:D,1) for first highest time value in D Column, and you
Can change the value 2 instead of 1 to get the second highest value (i.e.)
=LARGE(D:D,2) like this you can get your desired Results.

All the Best!

If this post helps, Click Yes!

--------------------
(MS-Exl-Learner)
--------------------



"GAIDEN" wrote:

I'm trying to lookup the time value 4:05:00 PM or the next highest time value.
I have:
B19 = 4:05:00 PM C19 = VLOOKUP(B19,D:D,1) D25 = 4:05:13 PM
D26 = 4:05:10 PM
D27 = 4:05:09 PM
D28 = 4:00:06 PM

I thought I'd get 4:00:06 PM as my answer but all I keep getting is 8:02:49
AM. What am I doing wrong?

  #3   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 2,389
Default lookup time value

My guess is that your problem is your column is not sorted. You need to have
your times in ascending order for Vlookup to work.

Regards,
Fred.


"GAIDEN" wrote in message
...
I'm trying to lookup the time value 4:05:00 PM or the next highest time
value.
I have:
B19 = 4:05:00 PM C19 = VLOOKUP(B19,D:D,1) D25 = 4:05:13 PM
D26 = 4:05:10 PM
D27 = 4:05:09 PM
D28 = 4:00:06 PM

I thought I'd get 4:00:06 PM as my answer but all I keep getting is
8:02:49
AM. What am I doing wrong?


  #4   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 1,766
Default lookup time value

Hi,

if you want the next highest value, please array enter this formula
(Ctrl+Shift+Enter)

=MIN(IF((D25:D28-$B$19)=0,D25:D28))

--
Regards,

Ashish Mathur
Microsoft Excel MVP
www.ashishmathur.com

"GAIDEN" wrote in message
...
I'm trying to lookup the time value 4:05:00 PM or the next highest time
value.
I have:
B19 = 4:05:00 PM C19 = VLOOKUP(B19,D:D,1) D25 = 4:05:13 PM
D26 = 4:05:10 PM
D27 = 4:05:09 PM
D28 = 4:00:06 PM

I thought I'd get 4:00:06 PM as my answer but all I keep getting is
8:02:49
AM. What am I doing wrong?


Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
LOOKUP and Time Calc Greg Excel Discussion (Misc queries) 4 July 24th 09 04:29 PM
LOOKUP FUNCTION? (LOOKUP VALUE BEING A TIME RENERATED FROM A FORMU JCC Excel Discussion (Misc queries) 5 June 26th 09 09:15 PM
Lookup and offset at the same time? TedT Excel Worksheet Functions 9 March 25th 08 04:15 AM
Lookup function one row at a time Sojo Excel Worksheet Functions 2 September 17th 07 03:44 PM
time lookup armyaviatr New Users to Excel 2 October 8th 05 02:40 PM


All times are GMT +1. The time now is 05:34 AM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Copyright ©2004-2024 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"