Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 271
Default Help with dates!! Excel 2003

I have two spreadsheets and i am trying to do a HLOOKUP however i get a #N/A

The problem: They both have the date 10/1/07 but if i change the one date
to 9/30/03 it will do the look and when i change the dates to general, the
numbers match with the different dates but not if they are both 10/1/07.

Please help! Any solutions, what causes this?


  #2   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 9,101
Default Help with dates!! Excel 2003

In the HLOOKUP use Datevalue("8/21/08") for the lookup value. The dates are
stored as numbers with 1 equaling Jan 1, 1900. It doesn't matter how you
format the cell the number value will still be the same.

"Susan" wrote:

I have two spreadsheets and i am trying to do a HLOOKUP however i get a #N/A

The problem: They both have the date 10/1/07 but if i change the one date
to 9/30/03 it will do the look and when i change the dates to general, the
numbers match with the different dates but not if they are both 10/1/07.

Please help! Any solutions, what causes this?


  #3   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 35,218
Default Help with dates!! Excel 2003

There's a setting that each workbook can have that determines the starting date
for excel.

In xl2003, it's under:
tools|options|calculation tab|check (or uncheck) 1904 date system

Most wintel users have this unchecked. Most Mac users check this.

But in your case, one workbook is using the 1904 date system and one workbook is
not.

You could uncheck this option and change all the dates in that workbook so that
the dates are consistent (checking the option in both workbooks is another way).

Saved from a previous post:

One workbook was using a base year of 1900 and the other was using 1904.
(tools|options|calculation tab|1904 date system)

One way to add those four years back is to find an empty cell, put 1462 into
that cell.

Copy that cell.

Select your range that contains the dates. Edit|PasteSpecial|click Add (in the
operation box).

You may have to reformat the cell as a date (mine turned to a 5 digit number).
But it should work.

You may want to do it against a copy...just in case.

(I'm not sure which one you'll fix. You may want to edit|pastespecial|click
subtract.)

Most windows users use 1900 as the base date. Mac users (mostly??) use 1904 as
the base date.

=============================

If you don't want to change the workbook's option and all its dates, you could
change your =hlookup() formula:

=hlookup(a1+1462, ....
or
=hlookup(a1-1462, ....

Depending on what workbook is using what option.

Susan wrote:

I have two spreadsheets and i am trying to do a HLOOKUP however i get a #N/A

The problem: They both have the date 10/1/07 but if i change the one date
to 9/30/03 it will do the look and when i change the dates to general, the
numbers match with the different dates but not if they are both 10/1/07.

Please help! Any solutions, what causes this?


--

Dave Peterson
  #4   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 271
Default Help with dates!! Excel 2003

Thank you!

I changed one of the worksheets!

"Dave Peterson" wrote:

There's a setting that each workbook can have that determines the starting date
for excel.

In xl2003, it's under:
tools|options|calculation tab|check (or uncheck) 1904 date system

Most wintel users have this unchecked. Most Mac users check this.

But in your case, one workbook is using the 1904 date system and one workbook is
not.

You could uncheck this option and change all the dates in that workbook so that
the dates are consistent (checking the option in both workbooks is another way).

Saved from a previous post:

One workbook was using a base year of 1900 and the other was using 1904.
(tools|options|calculation tab|1904 date system)

One way to add those four years back is to find an empty cell, put 1462 into
that cell.

Copy that cell.

Select your range that contains the dates. Edit|PasteSpecial|click Add (in the
operation box).

You may have to reformat the cell as a date (mine turned to a 5 digit number).
But it should work.

You may want to do it against a copy...just in case.

(I'm not sure which one you'll fix. You may want to edit|pastespecial|click
subtract.)

Most windows users use 1900 as the base date. Mac users (mostly??) use 1904 as
the base date.

=============================

If you don't want to change the workbook's option and all its dates, you could
change your =hlookup() formula:

=hlookup(a1+1462, ....
or
=hlookup(a1-1462, ....

Depending on what workbook is using what option.

Susan wrote:

I have two spreadsheets and i am trying to do a HLOOKUP however i get a #N/A

The problem: They both have the date 10/1/07 but if i change the one date
to 9/30/03 it will do the look and when i change the dates to general, the
numbers match with the different dates but not if they are both 10/1/07.

Please help! Any solutions, what causes this?


--

Dave Peterson

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
Dates in Excel 2003 Dermot Excel Discussion (Misc queries) 5 September 16th 07 04:22 PM
Dates in Excel 2003 Flaco Excel Discussion (Misc queries) 1 January 24th 06 03:32 AM
Excel 2003 dates mdob Excel Discussion (Misc queries) 2 July 14th 05 11:05 PM
dates in Excel 2003 [email protected] Excel Discussion (Misc queries) 3 January 4th 05 11:04 PM


All times are GMT +1. The time now is 11:39 PM.

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

About Us

"It's about Microsoft Excel"