Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 1
Default Day of week for pre 1900 dates


Does anyone have any ideas on how to derive the day of the week for a
list of pre-1900 dates, each of which is presented in a three cell
horizontal format YEAR MONTH DAY, ie 1685 March 21.
I have a spreadsheet with over 1300 lines in this format, so any
function or calculation that can be entered into a blank cell on each
line to get the actual day for that line is the preferred solution.
Thanks in advance.


--
ddmac
------------------------------------------------------------------------
ddmac's Profile: http://www.excelforum.com/member.php...o&userid=36185
View this thread: http://www.excelforum.com/showthread...hreadid=559593

  #2   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 1
Default Day of week for pre 1900 dates


Try this website

http://j-walk.com/ss/excel/files/xdate.htm


--
VBA Noob
------------------------------------------------------------------------
VBA Noob's Profile: http://www.excelforum.com/member.php...o&userid=33833
View this thread: http://www.excelforum.com/showthread...hreadid=559593

  #3   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 22
Default Day of week for pre 1900 dates

In cells A1, B1 and C1 enter year, month and day respectively.
In cell E1 enter
=DATE(A1+400,B1,C1)-DATE(A1+399,12,31)
In cell G1 enter
=INT((A1-1)/4)-INT((A1-1)/100)+INT((A1-1)/400)
In cell H1 enter
=365*(A1-1)+E1+G1
In cell I1 enter
=MOD(H1,7)+1
In cell J1 enter
=TEXT(I1,"dddd")
J1 should give the weekday for any date, not only for before a certain date.
The assumption here is that the calendar started on 1 January of the year 1
and that the rules for leap years were followed from then. Historically
there is more to it than this.


"ddmac" wrote:


Does anyone have any ideas on how to derive the day of the week for a
list of pre-1900 dates, each of which is presented in a three cell
horizontal format YEAR MONTH DAY, ie 1685 March 21.
I have a spreadsheet with over 1300 lines in this format, so any
function or calculation that can be entered into a blank cell on each
line to get the actual day for that line is the preferred solution.
Thanks in advance.


--
ddmac
------------------------------------------------------------------------
ddmac's Profile: http://www.excelforum.com/member.php...o&userid=36185
View this thread: http://www.excelforum.com/showthread...hreadid=559593


  #4   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 1
Default Day of week for pre 1900 dates


If you download John Walkenbach's XDATE functions as suggested above
then with your year, month, day, e.g. 1685, March, 21 in A1, B1, C1
then use this formula to get weekday in text format, e.g. Wednesday

=TEXT(XDATEDOW(XDATE(A1,MONTH("1 "&B1),C1)),"dddd")

note: assumes your using Excel's default 1900 date system. For the
example above it gives me "Wednesday"


--
daddylonglegs
------------------------------------------------------------------------
daddylonglegs's Profile: http://www.excelforum.com/member.php...o&userid=30486
View this thread: http://www.excelforum.com/showthread...hreadid=559593

  #5   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 3,440
Default Day of week for pre 1900 dates

And do read John's warning about limitations: you have to know what date system was in use where and when the date was
established; even in the 19th century there were several date differences between countries.

--
Kind regards,

Niek Otten
Microsoft MVP - Excel

"daddylonglegs" wrote in message
news:daddylonglegs.2amwmn_1152375002.7104@excelfor um-nospam.com...
|
| If you download John Walkenbach's XDATE functions as suggested above
| then with your year, month, day, e.g. 1685, March, 21 in A1, B1, C1
| then use this formula to get weekday in text format, e.g. Wednesday
|
| =TEXT(XDATEDOW(XDATE(A1,MONTH("1 "&B1),C1)),"dddd")
|
| note: assumes your using Excel's default 1900 date system. For the
| example above it gives me "Wednesday"
|
|
| --
| daddylonglegs
| ------------------------------------------------------------------------
| daddylonglegs's Profile: http://www.excelforum.com/member.php...o&userid=30486
| View this thread: http://www.excelforum.com/showthread...hreadid=559593
|


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
Retrieve multiple dates, from a week number? stonescar New Users to Excel 1 July 5th 06 05:05 PM
need to convert list of dates to count no. of dates by week neowok Excel Worksheet Functions 13 January 30th 06 03:54 PM
Macro to copy cells to rows below [email protected] Excel Discussion (Misc queries) 1 January 20th 06 06:59 PM
How do I combine a list of dates & a value into 1 week intervals Nathan Woodson Excel Discussion (Misc queries) 0 January 20th 06 01:39 AM
Macro to insert copied cells [email protected] Excel Discussion (Misc queries) 17 January 18th 06 10:40 AM


All times are GMT +1. The time now is 01:33 PM.

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"