Apr 12, 2005 #1 jbarbato Programmer Apr 6, 2005 56 US how do i convert a date of format mm/dd/yyyy to the 1900 date format of #####, where ##### is equal to the number of days after january 1, 1900? example - mm/dd/yyyy = # 01/01/1900 = 1 06/01/2003 = 37773 07/01/2003 = 37802
how do i convert a date of format mm/dd/yyyy to the 1900 date format of #####, where ##### is equal to the number of days after january 1, 1900? example - mm/dd/yyyy = # 01/01/1900 = 1 06/01/2003 = 37773 07/01/2003 = 37802
Apr 12, 2005 Thread starter #2 jbarbato Programmer Apr 6, 2005 56 US oops - i forgot to mention - i am using crystal reports xi Upvote 0 Downvote
Apr 12, 2005 1 #3 vidru Programmer Jul 18, 2003 2,113 US I don't think there's a built-in function that does this, but something like this might work for you, based on your given examples: DateDiff("d", Date(1899,12,31), {Table.DateField}); You can then format the resulting formula field to not show the decimals, if desired. -dave Upvote 0 Downvote
I don't think there's a built-in function that does this, but something like this might work for you, based on your given examples: DateDiff("d", Date(1899,12,31), {Table.DateField}); You can then format the resulting formula field to not show the decimals, if desired. -dave
Apr 12, 2005 1 #4 kskid Technical User Mar 21, 2003 1,767 US Try this. datediff("d",date(1899,12,31),DATE(1900,1,1)) = 1 datediff("d",date(1899,12,31),DATE(2003,6,1)) = 37772 datediff("d",date(1899,12,31),DATE(2003,7,1)) = 37802 -LW Upvote 0 Downvote
Try this. datediff("d",date(1899,12,31),DATE(1900,1,1)) = 1 datediff("d",date(1899,12,31),DATE(2003,6,1)) = 37772 datediff("d",date(1899,12,31),DATE(2003,7,1)) = 37802 -LW