+ Reply to Thread
Results 1 to 3 of 3

remove timestamp from date

  1. #1
    Registered User
    Join Date
    11-09-2006
    Posts
    65

    remove timestamp from date

    I want to use a cell that has a date as a vlookup value but the problem is that it fails to find the match because it has a time also included in the cell.
    The cell is already formated as 'date'.

    What is the best method to remove the time portion from that cell?
    Example cell below:

    3/14/2008 5:24:20 PM
    Last edited by surfengine; 03-03-2010 at 05:43 PM.

  2. #2
    Forum Expert Paul's Avatar
    Join Date
    02-05-2007
    Location
    Wisconsin
    MS-Off Ver
    2016/365
    Posts
    6,887

    Re: remove timestamp from date

    In your VLOOKUP try using something like:

    =VLOOKUP(INT(A1),$C$2:$D$100,2,0)

    where A1 holds the date/time value. As far as Excel is concerned, dates are whole numbers between 0 (Jan 1, 1900) and some large number. Time is a decimal number between 0 and 1, to account for percentage of the day. So INT(A1) will return just the date portion of that value.

  3. #3
    Registered User
    Join Date
    11-09-2006
    Posts
    65

    Re: remove timestamp from date

    totally worked.
    Last edited by Paul; 03-03-2010 at 05:56 PM.

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

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